compat_limitpain doesn't seem to work in MAPINFO

Bugs that have been investigated and resolved somehow.

Moderator: GZDoom Developers

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 Reply
User avatar
3saster
Posts: 199
Joined: Fri May 11, 2018 2:39 pm
Location: Canada

compat_limitpain doesn't seem to work in MAPINFO

Post by 3saster »

The compat_limitpain compatibility option does not seem to do anything in MAPINFO. For example, in the attached wad (actually just repackaged Hell Revealed MAP19), the pain elemental(s) at the very start should not be able to attack due to over 21 offscreen lost souls and the compat_limitpain = 1 line in the MAPINFO (until you grab the megasphere and the souls die). However, they can attack if you had the CVAR disabled beforehand, and it can be freely changed on the spot despite the MAPINFO supposed to be overridding the user setting. No error is given in the console however, which means the option is recognized. May affect other CVARs, but as far as I can tell it is just this one that doesn't work in MAPINFO for some reason.
PAINTEST.wad
Run with "+compat_limitpain 0 -warp 1 -skill 2" to immediately see the bug. Pain Elemental should not be able to attack unless you grab the megasphere.
(151.98 KiB) Downloaded 32 times
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: compat_limitpain doesn't seem to work in MAPINFO

Post by _mental_ »

3saster wrote:despite the MAPINFO supposed to be overridding the user setting
This is wrong and in fact it's quite the opposite. User's options always have precedence over mod's settings.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49067
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: compat_limitpain doesn't seem to work in MAPINFO

Post by Graf Zahl »

That is not correct for compatibility options. In order to work, a MAPINFO setting will always have to override the user setting.
_mental_
 
 
Posts: 3812
Joined: Sun Aug 07, 2011 4:32 am

Re: compat_limitpain doesn't seem to work in MAPINFO

Post by _mental_ »

I was wrong, it's a bug indeed.

Compatibility flags in ZScript are checked by accessing CVARs instead of internal variables.
There are only three occurrences in total, including this one.
Should we exposed those internal variables and compatibility flags to ZScript?
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49067
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: compat_limitpain doesn't seem to work in MAPINFO

Post by Graf Zahl »

Damn. Of course the 'compat_*' CVARs must be redirected to the internal variable that holds the modified values with MAPINFO and compatibility.txt being taken into account. The original CVARs should not be accessible from the script side.
Post Reply

Return to “Closed Bugs [GZDoom]”