diff --git a/src/p_setup.c b/src/p_setup.c index a47077ba5..e6b966824 100644 --- a/src/p_setup.c +++ b/src/p_setup.c @@ -4369,8 +4369,6 @@ boolean P_LoadLevel(boolean fromnetsave, boolean reloadinggamestate) P_SpawnSlopes(fromnetsave); - P_SpawnSpecialsAfterSlopes(); - P_SpawnMapThings(!fromnetsave); for (numcoopstarts = 0; numcoopstarts < MAXPLAYERS; numcoopstarts++) diff --git a/src/p_spec.c b/src/p_spec.c index 53d3b5370..d850f2a3f 100644 --- a/src/p_spec.c +++ b/src/p_spec.c @@ -6955,6 +6955,12 @@ void P_SpawnSpecialsThatRequireObjects(boolean fromnetsave) for (i = 0; i < numlines; i++) { + if (P_IsLineDisabled(&lines[i])) + { + /* remove the special so it can't even be found during the level */ + lines[i].special = 0; + } + switch (lines[i].special) { case 30: // Polyobj_Flag @@ -6968,29 +6974,7 @@ void P_SpawnSpecialsThatRequireObjects(boolean fromnetsave) case 32: // Polyobj_RotDisplace PolyRotDisplace(&lines[i]); break; - } - } - if (!fromnetsave) - P_RunLevelLoadExecutors(); -} - -/** Fuck ML_NONET - */ -void P_SpawnSpecialsAfterSlopes(void) -{ - size_t i; - - for (i = 0; i < numlines; ++i) - { - if (P_IsLineDisabled(&lines[i])) - { - /* remove the special so it can't even be found during the level */ - lines[i].special = 0; - } - - switch (lines[i].special) - { case 80: // Raise tagged things by type to this FOF { mtag_t tag = Tag_FGet(&lines[i].tags); @@ -7003,6 +6987,9 @@ void P_SpawnSpecialsAfterSlopes(void) break; } } + + if (!fromnetsave) + P_RunLevelLoadExecutors(); } /** Adds 3Dfloors as appropriate based on a common control linedef. diff --git a/src/p_spec.h b/src/p_spec.h index cbcbf366d..d1af15ec6 100644 --- a/src/p_spec.h +++ b/src/p_spec.h @@ -42,7 +42,6 @@ void P_SetupLevelFlatAnims(void); // at map load void P_InitSpecials(void); void P_SpawnSpecials(boolean fromnetsave); -void P_SpawnSpecialsAfterSlopes(void); void P_SpawnSpecialsThatRequireObjects(boolean fromnetsave); // every tic