mirror of
https://github.com/ZDoom/Raze.git
synced 2025-05-30 17:01:03 +00:00
- eu, that are not expActor
This commit is contained in:
parent
7147d3c89e
commit
e16caa0c62
2 changed files with 12 additions and 25 deletions
|
@ -1133,7 +1133,6 @@ DSWActor* DoPickTarget(DSWActor* actor, uint32_t max_delta_ang, int skip_targets
|
|||
short angle2, delta_ang;
|
||||
int dist, zh;
|
||||
SPRITEp ep;
|
||||
USERp eu;
|
||||
int16_t* shp;
|
||||
USERp u = actor->u();
|
||||
int ezh, ezhl, ezhm;
|
||||
|
@ -1152,19 +1151,17 @@ DSWActor* DoPickTarget(DSWActor* actor, uint32_t max_delta_ang, int skip_targets
|
|||
SWStatIterator it(*shp);
|
||||
while (auto itActor = it.Next())
|
||||
{
|
||||
eu = itActor->u();
|
||||
|
||||
// don't pick yourself
|
||||
if (actor == itActor)
|
||||
continue;
|
||||
|
||||
if (skip_targets != 2) // Used for spriteinfo mode
|
||||
{
|
||||
if (skip_targets && TEST(eu->Flags, SPR_TARGETED))
|
||||
if (skip_targets && TEST(itActor->user.Flags, SPR_TARGETED))
|
||||
continue;
|
||||
|
||||
// don't pick a dead player
|
||||
if (eu->PlayerP && TEST(eu->PlayerP->Flags, PF_DEAD))
|
||||
if (itActor->user.PlayerP && TEST(itActor->user.PlayerP->Flags, PF_DEAD))
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue