Merge branch 'join-assertion-perdition' into 'master'

P_NetUnArchiveThinkers: set thinker references to 0 before removing

Closes #514

See merge request KartKrew/Kart!1167
This commit is contained in:
toaster 2023-04-13 22:57:08 +00:00
commit c19755f157

View file

@ -4337,6 +4337,8 @@ static void P_NetUnArchiveThinkers(savebuffer_t *save)
{
next = currentthinker->next;
currentthinker->references = 0; // Heinous but this is the only place the assertion in P_UnlinkThinkers is wrong
if (currentthinker->function.acp1 == (actionf_p1)P_MobjThinker || currentthinker->function.acp1 == (actionf_p1)P_NullPrecipThinker)
P_RemoveSavegameMobj((mobj_t *)currentthinker); // item isn't saved, don't remove it
else