From 2aa84350cbac17f80f3a65dd40712f1d3687070e Mon Sep 17 00:00:00 2001 From: INeedBots Date: Fri, 26 Mar 2021 00:30:39 -0600 Subject: [PATCH] Swap on spawn --- main_shared/maps/mp/bots/_bot_script.gsc | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/main_shared/maps/mp/bots/_bot_script.gsc b/main_shared/maps/mp/bots/_bot_script.gsc index 36d8ac3..5b1a1d1 100644 --- a/main_shared/maps/mp/bots/_bot_script.gsc +++ b/main_shared/maps/mp/bots/_bot_script.gsc @@ -2529,6 +2529,7 @@ follow_target() } /* + Fast swaps or reload cancels don't work cause t5 bots wait for the anim to complete Bots will think to switch weapons */ bot_weapon_think() @@ -2536,6 +2537,8 @@ bot_weapon_think() self endon("death"); self endon("disconnect"); level endon("game_ended"); + + first = true; for(;;) { @@ -2556,13 +2559,23 @@ bot_weapon_think() if (isDefined(threat) && !isPlayer(threat)) continue; - if(curWeap != "none" && self getAmmoCount(curWeap) && curWeap != "strela_mp") + if (first) { - if(randomInt(100) > 2) + first = false; + + if (randomInt(100) > 10) continue; + } + else + { + if(curWeap != "none" && self getAmmoCount(curWeap) && curWeap != "strela_mp") + { + if(randomInt(100) > 2) + continue; - if(isDefined(threat)) - continue; + if(isDefined(threat)) + continue; + } } weaponslist = self getweaponslist();