mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 08:51:24 +00:00
- Exhumed: Fix incorrect distance check operator for the rat.
This commit is contained in:
parent
fe356f3183
commit
7c2bd266b9
1 changed files with 2 additions and 2 deletions
|
@ -260,7 +260,7 @@ void AIRat::Tick(RunListEvent* ev)
|
|||
|
||||
auto delta = pActor->spr.pos.XY() - pTarget->spr.pos.XY();
|
||||
|
||||
if (abs(delta.X) > CHECK_DIST || abs(delta.Y) >= CHECK_DIST)
|
||||
if (abs(delta.X) > CHECK_DIST || abs(delta.Y) > CHECK_DIST)
|
||||
{
|
||||
pActor->nAction = 2;
|
||||
pActor->nFrame = 0;
|
||||
|
@ -318,7 +318,7 @@ void AIRat::Tick(RunListEvent* ev)
|
|||
|
||||
auto delta = pActor->spr.pos.XY() - pTarget->spr.pos.XY();
|
||||
|
||||
if (abs(delta.X) > CHECK_DIST || abs(delta.Y) >= CHECK_DIST)
|
||||
if (abs(delta.X) > CHECK_DIST || abs(delta.Y) > CHECK_DIST)
|
||||
{
|
||||
pActor->nCount--;
|
||||
if (pActor->nCount < 0)
|
||||
|
|
Loading…
Reference in a new issue