- Fixed compatibility flags not working in scripting.

This commit is contained in:
drfrag 2020-05-03 18:19:26 +02:00
parent 80b3f8dcbe
commit 6a3f2b59cd
5 changed files with 6 additions and 6 deletions

View file

@ -195,7 +195,7 @@ extend class Actor
aimtarget.Height = Height; aimtarget.Height = Height;
bool shootmode = ((flags & MSF_Classic) || // Flag explicitly set, or no flags and compat options bool shootmode = ((flags & MSF_Classic) || // Flag explicitly set, or no flags and compat options
(flags == 0 && CurState.bDehacked && (Level.compatflags & COMPATF_MUSHROOM))); (flags == 0 && CurState.bDehacked && (compatflags & COMPATF_MUSHROOM)));
for (i = -numspawns; i <= numspawns; i += 8) for (i = -numspawns; i <= numspawns; i += 8)
{ {

View file

@ -86,7 +86,7 @@ extend class Actor
} }
// [RH] make this optional // [RH] make this optional
if (limit < 0 && (Level.compatflags & COMPATF_LIMITPAIN)) if (limit < 0 && (compatflags & COMPATF_LIMITPAIN))
limit = 21; limit = 21;
if (limit > 0) if (limit > 0)

View file

@ -634,7 +634,7 @@ extend class Actor
Actor mo; Actor mo;
double spawnz = 0; double spawnz = 0;
if (!(Level.compatflags & COMPATF_NOTOSSDROPS)) if (!(compatflags & COMPATF_NOTOSSDROPS))
{ {
int style = sv_dropstyle; int style = sv_dropstyle;
if (style == 0) if (style == 0)
@ -655,7 +655,7 @@ extend class Actor
{ {
mo.bDropped = true; mo.bDropped = true;
mo.bNoGravity = false; // [RH] Make sure it is affected by gravity mo.bNoGravity = false; // [RH] Make sure it is affected by gravity
if (!(Level.compatflags & COMPATF_NOTOSSDROPS)) if (!(compatflags & COMPATF_NOTOSSDROPS))
{ {
mo.TossItem (); mo.TossItem ();
} }

View file

@ -1944,7 +1944,7 @@ class PlayerPawn : Actor
override int GetMaxHealth(bool withupgrades) const override int GetMaxHealth(bool withupgrades) const
{ {
int ret = MaxHealth > 0? MaxHealth : ((Level.compatflags & COMPATF_DEHHEALTH)? 100 : deh.MaxHealth); int ret = MaxHealth > 0? MaxHealth : ((compatflags & COMPATF_DEHHEALTH)? 100 : deh.MaxHealth);
if (withupgrades) ret += stamina + BonusHealth; if (withupgrades) ret += stamina + BonusHealth;
return ret; return ret;
} }

View file

@ -347,7 +347,7 @@ class Minotaur : Actor
} }
else else
{ {
if (Floorclip > 0 && (Level.compatflags & COMPAT_MINOTAUR)) if (Floorclip > 0 && (compatflags & COMPAT_MINOTAUR))
{ {
// only play the sound. // only play the sound.
A_StartSound ("minotaur/fx2hit", CHAN_WEAPON); A_StartSound ("minotaur/fx2hit", CHAN_WEAPON);