Page 1 of 1

[FIXED] Doom2 Map05: TAG 9 bug

Posted: Sun Oct 18, 2020 2:16 am
by Lobo
The MAP05 thing is related to how the sector with the blue armor and shotgun guys is incorrectly tagged with tag #9, which is also used on one of the doors nearby to a little room with an imp and some shotgun cells. So when you open that door it also tries to open the sector with the MegaArmor.

The same map bug affects the secret area near the end where the cacodemons are, since that area is also tagged with tag #9.
The same bug occurs in original DOOM, except that it shows HOM (missing texture) where EDGE shows a black texture.

More info here: https://doomwiki.org/wiki/MAP05:_The_Wa ... _(Doom_II)
"If the player opens the westernmost door (sector 46) in the short hall with the series of doors while using no monsters mode, the ceilings of the combat armor chamber (4) and the alcoves to either side of the exit (153) will lower all the way to the floors, preventing the entrances into the rooms from ever opening. Due to an unknown reason, the two mentioned areas share tag number 9 with the westernmost door. They are thus activated as well when the door is opened, and since the ceiling heights of their adjacent sectors (the closed doors) are at the same level as their floors, the ceilings will actually move four units past the floors. During normal gameplay, it does not cause problems as the present monsters prevent the movement.
The backsides of linedefs 489 and 560 are missing upper textures, resulting in both having a hall of mirrors effect."

Re: Doom2 Map05: TAG 9 bug

Posted: Sun Oct 18, 2020 2:26 am
by Lobo
I'm wondering if some kind of RTS script could get around this issue?

Re: Doom2 Map05: TAG 9 bug

Posted: Sun Oct 18, 2020 11:28 am
by Lobo
OK. Here is the fix for this bug. I humbly recommend this be included in the stock RTS script for the next release of EDGE:

START_MAP map05

//Workaround for a bug in Doom2 where TAG 9 is used incorrectly
RADIUS_TRIGGER 0 0 -1

//Just raise the ceiling back up as soon as we detect it goes down.
onceilingheight 90 199 4

wait 1T //must wait a little bit or it doesn't run
move_sector 9 104 ceiling

END_RADIUS_TRIGGER

END_MAP

Re: Doom2 Map05: TAG 9 bug

Posted: Sun Oct 18, 2020 3:02 pm
by Corbachu
I can do this. As long as map authors who develop for EDGE and have MaP05 remember that this is in the base doom_ddf definitions I don’t see a problem with it. Might want to add additional tag information for SP/MP/etc...I’ll play around with it.

@Lobo: if you have time, open a PR on GitHub with these changes so you are properly attributed. If not just tell me and I’ll mention it in changelog 😝

Re: [PENDING] Doom2 Map05: TAG 9 bug

Posted: Sun Oct 18, 2020 11:31 pm
by Lobo
I don't care as long as it is fixed 😉

Re: [PENDING] Doom2 Map05: TAG 9 bug

Posted: Tue Oct 20, 2020 11:25 am
by Lobo
OK, the previous script wasn't perfect.
This is the perfect one :

START_MAP map05

//Workaround for a bug in Doom2 where TAG 9 is used incorrectly
RADIUS_TRIGGER 0 0 -1

//As soon as we detect it goes down.
onceilingheight 90 199 4 //sector 4 is the first problematic one

wait 1T //must wait a little bit or it doesn't run

SECTORV 4 104 ceiling //Just raise the ceiling back up for sector 4
SECTORV 153 80 ceiling //Just raise the ceiling back up for sector 153

END_RADIUS_TRIGGER

END_MAP

Re: [FIXED] Doom2 Map05: TAG 9 bug

Posted: Tue Nov 03, 2020 8:18 pm
by Corbachu
Fixed@5c0ed.