mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-11 07:11:54 +00:00
- Fixed crash with corpse queueing.
This commit is contained in:
parent
1ee9256842
commit
259e3127fe
1 changed files with 9 additions and 6 deletions
|
@ -125,16 +125,19 @@ DCorpsePointer::DCorpsePointer (AActor *ptr)
|
|||
TThinkerIterator<DCorpsePointer> iterator (STAT_CORPSEPOINTER);
|
||||
DCorpsePointer *first = iterator.Next ();
|
||||
|
||||
if (first != nullptr)
|
||||
{
|
||||
if (first != this)
|
||||
{
|
||||
if (first->Count >= (uint32_t)sv_corpsequeuesize)
|
||||
{
|
||||
DCorpsePointer *next = iterator.Next ();
|
||||
first->Destroy ();
|
||||
DCorpsePointer *next = iterator.Next();
|
||||
first->Destroy();
|
||||
first = next;
|
||||
}
|
||||
}
|
||||
++first->Count;
|
||||
}
|
||||
}
|
||||
|
||||
void DCorpsePointer::OnDestroy ()
|
||||
|
|
Loading…
Reference in a new issue