mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-02-01 19:26:11 +00:00
I just checked how P_LookForPlayers works, and it turns out it doesn't modify the target *unless* it returns true. So I guess we've no need to account for a change in target in A_LookForBetter after all?
This commit is contained in:
parent
d159cddde6
commit
2702b998ed
1 changed files with 1 additions and 6 deletions
|
|
@ -12385,16 +12385,11 @@ void A_LookForBetter(mobj_t *actor)
|
|||
{
|
||||
INT32 locvar1 = var1;
|
||||
//INT32 locvar2 = var2;
|
||||
mobj_t *oldtarget = NULL;
|
||||
#ifdef HAVE_BLUA
|
||||
if (LUA_CallAction("A_LookForBetter", actor))
|
||||
return;
|
||||
#endif
|
||||
|
||||
oldtarget = actor->target;
|
||||
|
||||
if (!P_LookForPlayers(actor, (locvar1 & 65535), false, FixedMul((locvar1 >> 16)*FRACUNIT, actor->scale)))
|
||||
actor->target = oldtarget;
|
||||
|
||||
P_LookForPlayers(actor, (locvar1 & 65535), false, FixedMul((locvar1 >> 16)*FRACUNIT, actor->scale));
|
||||
A_FaceTarget(actor);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue