mirror of
https://github.com/ineedbots/iw3_bot_warfare.git
synced 2025-04-21 01:55:43 +00:00
distance
This commit is contained in:
parent
954531a091
commit
e5fabd772d
@ -1094,7 +1094,7 @@ walk()
|
|||||||
goal = PhysicsTrace(goal + (0, 0, 50), goal + (0, 0, -40), false, self);
|
goal = PhysicsTrace(goal + (0, 0, 50), goal + (0, 0, -40), false, self);
|
||||||
|
|
||||||
// too small, lets bounce off the wall
|
// too small, lets bounce off the wall
|
||||||
if (Distance(goal, myOrg) < stepDist - 1 || randomInt(100) < 5)
|
if (DistanceSquared(goal, myOrg) < stepDist*stepDist - 1 || randomInt(100) < 5)
|
||||||
{
|
{
|
||||||
trace = bulletTrace(myOrg, myOrg + forward, false, self);
|
trace = bulletTrace(myOrg, myOrg + forward, false, self);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user