mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-12 23:54:17 +00:00
- fixed (un)morphing of more than one actor from ACS
https://forum.zdoom.org/viewtopic.php?t=68847
This commit is contained in:
parent
11ba0be4c2
commit
8a1091c6fe
1 changed files with 14 additions and 4 deletions
|
@ -10027,9 +10027,14 @@ scriptwait:
|
|||
else
|
||||
{
|
||||
auto iterator = Level->GetActorIterator(tag);
|
||||
AActor *actor;
|
||||
TArray<AActor*> actorsToMorph;
|
||||
|
||||
while ( (actor = iterator.Next ()) )
|
||||
while (AActor *actor = iterator.Next())
|
||||
{
|
||||
actorsToMorph.Push(actor);
|
||||
}
|
||||
|
||||
for (AActor *actor : actorsToMorph)
|
||||
{
|
||||
changes += P_MorphActor(activator, actor, playerclass, monsterclass, duration, style, morphflash, unmorphflash);
|
||||
}
|
||||
|
@ -10053,9 +10058,14 @@ scriptwait:
|
|||
else
|
||||
{
|
||||
auto iterator = Level->GetActorIterator(tag);
|
||||
AActor *actor;
|
||||
TArray<AActor*> actorsToUnmorph;
|
||||
|
||||
while ( (actor = iterator.Next ()) )
|
||||
while (AActor *actor = iterator.Next())
|
||||
{
|
||||
actorsToUnmorph.Push(actor);
|
||||
}
|
||||
|
||||
for (AActor *actor : actorsToUnmorph)
|
||||
{
|
||||
changes += P_UnmorphActor(activator, actor, 0, force);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue