- moved main polyobject array into FLevelLocals and simplified the setup process to not depend on P_SpawnMapThing.

Since the SpawnedThings array is still available when polyobjects are spawned it makes no sense to create an expensive linked list in P_SpawnMapThing.
This can be done far better by scanning through the array again and collect all matching items in a second array.
This commit is contained in:
Christoph Oelckers 2018-12-28 10:08:39 +01:00
commit 64595abe60
12 changed files with 72 additions and 126 deletions

View file

@ -2333,10 +2333,9 @@ void AM_showSS()
AM_drawSeg(sub->firstline + i, yellow);
}
for (int i = 0; i <po_NumPolyobjs; i++)
for (auto &poly : level.Polyobjects)
{
FPolyObj *po = &polyobjs[i];
FPolyNode *pnode = po->subsectorlinks;
FPolyNode *pnode = poly.subsectorlinks;
while (pnode != NULL)
{