mirror of
https://github.com/DrBeef/Raze.git
synced 2025-02-20 18:52:43 +00:00
- missed one last DistanceI call in ai.cpp
This commit is contained in:
parent
145b563736
commit
9cd3b3456a
1 changed files with 2 additions and 4 deletions
|
@ -1356,8 +1356,6 @@ int InitActorFindPlayer(DSWActor* actor)
|
|||
|
||||
int InitActorDuck(DSWActor* actor)
|
||||
{
|
||||
int dist;
|
||||
|
||||
if (!actor->user.ActorActionSet->Duck)
|
||||
{
|
||||
actor->user.ActorActionFunc = DoActorDecide;
|
||||
|
@ -1367,9 +1365,9 @@ int InitActorDuck(DSWActor* actor)
|
|||
actor->user.ActorActionFunc = DoActorDuck;
|
||||
NewStateGroup(actor, actor->user.ActorActionSet->Duck);
|
||||
|
||||
dist = DistanceI(actor->spr.pos, actor->user.targetActor->spr.pos);
|
||||
double dist = (actor->spr.pos.XY(), actor->user.targetActor->spr.pos.XY()).LengthSquared();
|
||||
|
||||
if (dist > 8000)
|
||||
if (dist > 500*500)
|
||||
{
|
||||
actor->user.WaitTics = 190;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue