mirror of
https://github.com/ineedbots/t4_bot_warfare.git
synced 2025-04-23 00:15:44 +00:00
flared movement
This commit is contained in:
parent
1f5c23f275
commit
7b1973a689
@ -1926,7 +1926,24 @@ killWalkOnEvents()
|
|||||||
self endon( "disconnect" );
|
self endon( "disconnect" );
|
||||||
self endon( "death" );
|
self endon( "death" );
|
||||||
|
|
||||||
self waittill_any( "flash_rumble_loop", "new_enemy", "new_goal_internal", "goal_internal", "bad_path_internal" );
|
self waittill_any( "new_enemy", "new_goal_internal", "goal_internal", "bad_path_internal" );
|
||||||
|
|
||||||
|
waittillframeend;
|
||||||
|
|
||||||
|
self notify( "kill_goal" );
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Will stop the goal walk when an enemy is found or flashed or a new goal appeared for the bot.
|
||||||
|
*/
|
||||||
|
watchOnFlared()
|
||||||
|
{
|
||||||
|
self endon( "kill_goal" );
|
||||||
|
self endon( "disconnect" );
|
||||||
|
self endon( "death" );
|
||||||
|
|
||||||
|
while ( !self isFlared() )
|
||||||
|
wait 0.05;
|
||||||
|
|
||||||
waittillframeend;
|
waittillframeend;
|
||||||
|
|
||||||
@ -1963,6 +1980,7 @@ doWalk( goal, dist, isScriptGoal )
|
|||||||
self thread doWalkScriptNotify();
|
self thread doWalkScriptNotify();
|
||||||
|
|
||||||
self thread killWalkOnEvents();
|
self thread killWalkOnEvents();
|
||||||
|
self thread watchOnFlared();
|
||||||
self thread watchOnGoal( goal, dist );
|
self thread watchOnGoal( goal, dist );
|
||||||
|
|
||||||
current = self initAStar( goal );
|
current = self initAStar( goal );
|
||||||
|
Loading…
x
Reference in New Issue
Block a user