Description
This is related to #1205 - big thanks to @SmileTheory for the work! - we're almost there.
Tested with today's daily build as well as Crispy (cf. fabiangreffrath#500).
Case 1
1_ON_1.WAD with the accompanying v1.2 demo
cmdline
-iwad doom.wad -file 1_ON_1.WAD -playdemo 1_ON_1 -gameversion 1.2
Observed behavior:
Sectors 305 and 308 -- segments (second from the south) of the walkways over the nukage that lead to the BFG in the south - fail to rise.
Expected behavior:
Sectors 305 and 308 are supposed to rise to the level of the adjacent walkway segments, the way it works in the v1.2 vanilla. Prb+ doesn't emulate this 100% (they rise slightly higher), yet plays the demo successfully to the end.
Case 2
The exit bridge (sector 232) on RETURN01 E1M2 and my old v1.2 UV Max.
These are the only two troublesome v1.2 demos I've encountered out of a couple dozen tested so far. The two issues are similar but not the same. In the RETURN01 case there is no higher floor adjacent to the target sector; in the 1_ON_1 case there are two sets of four sectors, each daisy-chained, and the northernmost and southernmost of the sectors do have higher-floor neighbors.
Here's a diagram of the area in question:
link
The switch (S1) is tagged to the sector pairs 1, 2 and 3. The fourth pair is tagged to another switch (S2), in the secret next to the Cybers in the east. The red numbers are the floor heights.
In v1.9 and current v1.2 compat implementation, sector pairs 1 and 4 always rise; sector pair 3 (i.e., the above-mentioned sectors 305 and 308) only if S2 is activated before S1. Sector pair 2 never rises.
In vanilla v1.2 all the tagged sectors rise to -20 when the corresponding switches are activated, regardless of the order of switch activation.
P_FindNextHighestFloor is the prime suspect, naturally; but I'd also like to point out the following code from Prboom-plus' p_spec.c:486:
/* cph - my guess at doom v1.2 - 1.4beta compatibility here.
* If there are no higher neighbouring sectors, Heretic just returned
* heightlist[0] (local variable), i.e. noise off the stack. 0 is right for
* RETURN01 E1M2, so let's take that. */
return (compatibility_level < doom_1666_compatibility ? 0 : currentheight);
This part seems to have been overlooked during the cribbing process. ;) I suspect there might be more as it's not readily apparent how that code would help in the 1_ON_1 case.