diff --git a/AutismBotIngame/scripting/autism_bot_info.sp b/AutismBotIngame/scripting/autism_bot_info.sp index 15a4331c..b51df7bf 100644 --- a/AutismBotIngame/scripting/autism_bot_info.sp +++ b/AutismBotIngame/scripting/autism_bot_info.sp @@ -413,9 +413,14 @@ public bool is_bot_player(int client) public Action recursive_pressing(Handle timer, any data) { + bool found_valid_ct = false; for (int client = 1; client <= MaxClients; client++) { if (!IsValidClient(client)) continue; + if (!is_bot_player(client) && GetClientTeam(client) == 3) + { + found_valid_ct = true; + } if (is_bot_player(client)) { if (GetClientTeam(client) == 1 || GetClientTeam(client) == 0) @@ -517,6 +522,17 @@ public Action recursive_pressing(Handle timer, any data) } } } + if (!found_valid_ct) + { + for (int client = 1; client <= MaxClients; client++) + { + if (!IsValidClient(client)) continue; + if (is_bot_player(client) && GetClientTeam(client) == 3) + { + ForcePlayerSuicide(client); + } + } + } return Plugin_Continue; }