This is the beginning of a larger project, a workaround for the director_no_survivor_bots crash.
The following script is intended to slay all survivor bots at the beginning of the round. I'd like to know why it isn't working. If anyone can help, I'd be very thankful.
PHP Code:
public OnPluginStart()
{
HookEvent("player_entered_start_area", PlayerEnteredStartArea);
}
public Action: PlayerEnteredStartArea(Handle:event, const String:name[], bool:dontBroadcast)
{
new playerSpawned = GetClientOfUserId(GetEventInt(event, "userid"));
if (IsFakeClient(playerSpawned))
{
ServerCommand("sm_slay", playerSpawned);
}
}