MAPINFO - checkswitchrange no longer accounts for 3D floors

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: MAPINFO - checkswitchrange no longer accounts for 3D floors

Re: MAPINFO - checkswitchrange no longer accounts for 3D flo

by _mental_ » Mon Feb 11, 2019 1:54 pm

Fixed in eaf0ac1.

Re: MAPINFO - checkswitchrange no longer accounts for 3D flo

by GooberMan » Sun Dec 30, 2018 12:30 pm

Compatibility + new MAPINFO flag would be preferred. I was testing PD because a colleague wants to play it, I'm inclined to do some more bugfixes while I'm there and upload a new version. If I recall, the compat system worked off file name and/or file hash? I'd rather preserve the behavior in any update I make.

EDIT: Checked the code, yeah, I see how that managed to just work since the player's Z equaled the sector Z. So tl;dr is that the MAPINFO flag would want to be the correct version that checks 3D floors in the back sector.

Re: MAPINFO - checkswitchrange no longer accounts for 3D flo

by Graf Zahl » Sun Dec 30, 2018 9:54 am

To summarize, this appeared to have worked solely by happenstance, not by design - to be precise, it "worked" because the function was bugged. If you look at the code, it never performs any checks whatsoever on 3D floors.

The only possible solution here looks like adding some compatibility handler

Re: MAPINFO - checkswitchrange no longer accounts for 3D flo

by _mental_ » Sun Dec 30, 2018 9:25 am

It was introduced with this pull request because of the change in this line. It seems to be a fix for similar issue which broke your map as a side effect :?

MAPINFO - checkswitchrange no longer accounts for 3D floors

by GooberMan » Tue Dec 25, 2018 8:45 am

Worked at the time of Prime Directive's release in June 2015.

Fairly early recognisable break with this behavior:
  • Console - map ge5map02
  • Press J to skip the cutscene
  • Run forward to the landing pad. Notice door on left of brick wall ahead of you. Run to it.
  • Attempt to use the door
The door is a 3D floor controlled by a script, which when used makes it look just like a real door. Notice that you can run on top of the brick wall where the door would be. checkswitchrange was enabled in MAPINFO to stop people pressing use and activating the door when they're obviously not next to it in a three-dimensional sense.

Bump behavior works just fine, but this is a Doom map not a Quake map. The bump constantly retriggers if you keep walking in to it though, so you get spammed use sounds and console message about the door needing a yellow key.

Top