Raised This Month: $51 Target: $400
 12% 

[L4D/L4D2] Infected Bots Control (1.0.0)


Post New Thread Reply   
 
Thread Tools Display Modes
HarryPotter
Veteran Member
Join Date: Sep 2017
Location: Taiwan, Asia
Old 01-03-2021 , 22:15   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1511

Fixed.

[L4D/L4D2] Infected Bots Control Impoved Version 2.5.0 (2021/1/4)
- fixed l4d1 doesn't have "z_finale_spawn_mob_safety_range" convar (thanks darkbret for reporting)
__________________
HarryPotter is offline
jeremyvillanueva
AlliedModders Donor
Join Date: Jan 2021
Location: dcord:Jeremy333#7632
Old 02-07-2021 , 21:19   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1512

Hi, I got a problem,
I'm using a fork version of your plugin,

I do have this messages sometimes:
[TS] Smokers 0,Boomers 0, Hunters 0, Tanks 0, Spitters 0, Jockeys 0, Chargers 0
[TS] !binfectedfreeplayer and case 1 smoker, min dist 300
CreatePlayerBot: Unable to create bot Smoker Bot - CreateFakeClient() returned NULL.
Spawned an infected bot. Type = 1

I was in Dead Air with 15 players, there were not tanks spawned
I got this log messages:
[TS] Smokers 0,Boomers 0, Hunters 0, Tanks 0, Spitters 0, Jockeys 0, Chargers 0
CreatePlayerBot: Unable to create bot Boomer Bot - CreateFakeClient() returned NULL.
Spawned an infected bot. Type = 2
CreatePlayerBot: Unable to create bot Tank - CreateFakeClient() returned NULL.

Does it is because of my maxplayers settings?
jeremyvillanueva is offline
HarryPotter
Veteran Member
Join Date: Sep 2017
Location: Taiwan, Asia
Old 02-08-2021 , 23:19   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1513

Quote:
Originally Posted by jeremyvillanueva View Post
Hi, I got a problem,
I'm using a fork version of your plugin,

I do have this messages sometimes:
[TS] Smokers 0,Boomers 0, Hunters 0, Tanks 0, Spitters 0, Jockeys 0, Chargers 0
[TS] !binfectedfreeplayer and case 1 smoker, min dist 300
CreatePlayerBot: Unable to create bot Smoker Bot - CreateFakeClient() returned NULL.
Spawned an infected bot. Type = 1

I was in Dead Air with 15 players, there were not tanks spawned
I got this log messages:
[TS] Smokers 0,Boomers 0, Hunters 0, Tanks 0, Spitters 0, Jockeys 0, Chargers 0
CreatePlayerBot: Unable to create bot Boomer Bot - CreateFakeClient() returned NULL.
Spawned an infected bot. Type = 2
CreatePlayerBot: Unable to create bot Tank - CreateFakeClient() returned NULL.

Does it is because of my maxplayers settings?
As it says, "CreatePlayerBot: Unable to create bot Boomer Bot - CreateFakeClient() returned NULL."
check if console print error like this
Quote:
Couldn't find a tank Spawn position in 5 tries
Couldn't find a jockey Spawn position in 5 tries
Couldn't find a spitter Spawn position in 5 tries
Couldn't find a spitter Spawn position in 5 tries
Couldn't find a jockey Spawn position in 5 tries
Couldn't find a smoker Spawn position in 5 tries
Couldn't find a jockey Spawn position in 5 tries
Couldn't find a smoker Spawn position in 5 tries
Couldn't find a spitter Spawn position in 5 tries
Couldn't find a jockey Spawn position in 5 tries
Couldn't find a hunter Spawn position in 5 tries
Couldn't find a hunter Spawn position in 5 tries
Couldn't find a spitter Spawn position in 5 tries
Couldn't find a charger Spawn position in 5 tries
Couldn't find a smoker Spawn position in 5 tries
Couldn't find a boomer Spawn position in 5 tries
Couldn't find a boomer Spawn position in 5 tries
Couldn't find a smoker Spawn position in 5 tries
I can't do anything about the infected spawn pathfinding, only Valve can handle that.
__________________

Last edited by HarryPotter; 02-08-2021 at 23:19.
HarryPotter is offline
jeremyvillanueva
AlliedModders Donor
Join Date: Jan 2021
Location: dcord:Jeremy333#7632
Old 02-09-2021 , 01:00   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1514

Oh thank you, yep I was having those messages,
and I fixed those adding more spawn min and finale distance, which I don't really understand now how it's used,
I also noted that maybe it has something to do with the maxplayers because whenever there was 15 players there was an Infected spawning, but when the 16th player entered the game, there were no spawns of SI, I think is my l4dtoolz version,
Thanks again,

I got it, I discovered it using the log
It said also:
Zombie tried to spawn under displacement in nav area 22632, setpos 10025.0 -5633.1 -65.1

So, I have disabled the modifications on the cvars from bots, (I was using the l4d2_competitive_bots_survivor plugin)
and the meshes were fixed, so spawning was enabled for all!!

Thanks again!!

Last edited by jeremyvillanueva; 02-09-2021 at 12:15.
jeremyvillanueva is offline
jeremyvillanueva
AlliedModders Donor
Join Date: Jan 2021
Location: dcord:Jeremy333#7632
Old 02-24-2021 , 20:12   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1515

I want to publish my fork
I have added nice features,
SpawnTime in Waves, also for Finales, Multiply SI for Finales, and others
https://github.com/jeremyvillanuevar...bots/scripting


Well, after trying to make a better Infected Bots control with a lot of plugins
I just ended working on VScript
This is what I'm doing:
https://forums.alliedmods.net/showthread.php?p=2740475

Last edited by jeremyvillanueva; 03-14-2021 at 18:35.
jeremyvillanueva is offline
sorallll
Senior Member
Join Date: Oct 2018
Old 02-26-2021 , 07:36   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1516

Human players on the infected team in coop mode.
Tanks will stuck in "stasis" until they die.

PHP Code:
Handle g_hLeaveStasis;

public 
Action Event_PlayerSpawn(Event event, const char[] namebool dontBroadcast
{
    
int userid event.GetInt("userid");
    
int client GetClientOfUserId(userid);
    if(
client == || !IsClientInGame(client) || GetClientTeam(client) != 3)
        return;

    if(!
IsClientInKickQueue(client) && IsFakeClient(client) && GetEntProp(clientProp_Send"m_zombieClass") == 8)
    {
        if((
GetTeamPlayers(3) >= && IsCoop())
            
CreateTimer(0.1Timer_UnstuckTankuseridTIMER_FLAG_NO_MAPCHANGE);
     }
}

stock int GetTeamPlayers(int iTeam=-1)
{
    
int iPlayersiTeamPlayers;
    for(
int i 1<= MaxClientsi++)
    {
        if(
IsClientInGame(i) && !IsFakeClient(i))
        {
            if(
iTeam 0)
            {
                
iPlayers++;
                continue;
            }

            if(
GetClientTeam(i) == iTeam)
                
iTeamPlayers++;
        }
    }

    return 
iTeam iPlayers iTeamPlayers;
}

bool IsCoop() 
{
    
char sGameMode[16];
    
FindConVar("mp_gamemode").GetString(sGameModesizeof(sGameMode));
    return 
strcmp(sGameMode"versus"false) != && strcmp(sGameMode"scavenge"false) != 0;
}

public 
Action Timer_UnstuckTank(Handle timerint client)
{
    if((
client GetClientOfUserId(client)) && IsClientInGame(client) && IsFakeClient(client) && GetClientTeam(client) == && IsPlayerAlive(client) && GetEntProp(clientProp_Send"m_zombieClass") == 8
        
SDKCall(g_hLeaveStasisclient);
}

//SDK
//Found by BHaType  https://forums.alliedmods.net/showthread.php?t=319342
void PrepSDKCall()
{
    
StartPrepSDKCall(SDKCall_Player);
    if(
PrepSDKCall_SetFromConf(hGameDataSDKConf_Signature"Tank::LeaveStasis") == false//https://forums.alliedmods.net/showthread.php?t=319342
        
SetFailState("Tank::LeaveStasis Signature broken.");
    else
    {
        
PrepSDKCall_SetReturnInfo(SDKType_PlainOldDataSDKPass_Plain);
        
g_hLeaveStasis EndPrepSDKCall();
        if(
g_hLeaveStasis == null)
            
SetFailState("Failed to create SDKCall: Tank::LeaveStasis");
    }

sorallll is offline
HarryPotter
Veteran Member
Join Date: Sep 2017
Location: Taiwan, Asia
Old 02-26-2021 , 17:53   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1517

Quote:
Originally Posted by sorallll View Post
Human players on the infected team in coop mode.
Tanks will stuck in "stasis" until they die.
What do you mean stasis?
__________________
HarryPotter is offline
Psyk0tik
Veteran Member
Join Date: May 2012
Location: Homeless
Old 02-26-2021 , 18:15   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1518

Quote:
Originally Posted by HarryPotter View Post
What do you mean stasis?
Basically, the "ghost mode" for the Tank, like in Versus mode when an AI Tank spawns and is waiting for a player to take control. In Co-op mode, Tanks automatically exit stasis mode as soon as they spawn on the map. Tanks usually only get "stuck" in stasis mode when the server has plugins that allow players to take over special infected in Co-op mode, like this one.
__________________
Psyk0tik is offline
sorallll
Senior Member
Join Date: Oct 2018
Old 02-26-2021 , 18:20   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1519

Quote:
Originally Posted by HarryPotter View Post
What do you mean stasis?
Invisible Tank in coop
sorallll is offline
HarryPotter
Veteran Member
Join Date: Sep 2017
Location: Taiwan, Asia
Old 02-27-2021 , 07:32   Re: [L4D/L4D2] Infected Bots Control (1.0.0)
Reply With Quote #1520

I'm pretty sure I have fixed the ghost tank bug in coop mode in my plugin
__________________

Last edited by HarryPotter; 02-27-2021 at 07:33.
HarryPotter is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:28.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode