mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-26 22:11:43 +00:00
Merge branch 'master' of https://github.com/rheit/zdoom
This commit is contained in:
commit
36a4352867
13 changed files with 83 additions and 23 deletions
|
@ -42,7 +42,7 @@ DEFINE_SPECIAL(Ceiling_LowerByValue, 40, 3, 5, 5)
|
|||
DEFINE_SPECIAL(Ceiling_RaiseByValue, 41, 3, 4, 4)
|
||||
DEFINE_SPECIAL(Ceiling_CrushAndRaise, 42, 3, 4, 4)
|
||||
DEFINE_SPECIAL(Ceiling_LowerAndCrush, 43, 3, 4, 4)
|
||||
DEFINE_SPECIAL(Ceiling_CrushStop, 44, 1, 1, 1)
|
||||
DEFINE_SPECIAL(Ceiling_CrushStop, 44, 1, 2, 2)
|
||||
DEFINE_SPECIAL(Ceiling_CrushRaiseAndStay, 45, 3, 4, 4)
|
||||
DEFINE_SPECIAL(Floor_CrushStop, 46, 1, 1, 1)
|
||||
DEFINE_SPECIAL(Ceiling_MoveToValue, 47, 3, 5, 5)
|
||||
|
@ -59,7 +59,7 @@ DEFINE_SPECIAL(Sector_SetPortal, 57, -1, -1, 5)
|
|||
DEFINE_SPECIAL(Sector_CopyScroller, 58, -1, -1, 2)
|
||||
DEFINE_SPECIAL(Polyobj_OR_MoveToSpot, 59, 3, 3, 3)
|
||||
DEFINE_SPECIAL(Plat_PerpetualRaise, 60, 3, 3, 3)
|
||||
DEFINE_SPECIAL(Plat_Stop, 61, 1, 1, 1)
|
||||
DEFINE_SPECIAL(Plat_Stop, 61, 1, 2, 2)
|
||||
DEFINE_SPECIAL(Plat_DownWaitUpStay, 62, 3, 3, 3)
|
||||
DEFINE_SPECIAL(Plat_DownByValue, 63, 4, 4, 4)
|
||||
DEFINE_SPECIAL(Plat_UpWaitDownStay, 64, 3, 3, 3)
|
||||
|
|
|
@ -109,7 +109,6 @@ static FCompatOption Options[] =
|
|||
{ "ignoreteleporttags", BCOMPATF_BADTELEPORTERS, SLOT_BCOMPAT },
|
||||
{ "rebuildnodes", BCOMPATF_REBUILDNODES, SLOT_BCOMPAT },
|
||||
{ "linkfrozenprops", BCOMPATF_LINKFROZENPROPS, SLOT_BCOMPAT },
|
||||
{ "disablepushwindowcheck", BCOMPATF_NOWINDOWCHECK, SLOT_BCOMPAT },
|
||||
{ "floatbob", BCOMPATF_FLOATBOB, SLOT_BCOMPAT },
|
||||
{ "noslopeid", BCOMPATF_NOSLOPEID, SLOT_BCOMPAT },
|
||||
|
||||
|
@ -149,6 +148,7 @@ static FCompatOption Options[] =
|
|||
{ "pointonline", COMPATF2_POINTONLINE, SLOT_COMPAT2 },
|
||||
{ "multiexit", COMPATF2_MULTIEXIT, SLOT_COMPAT2 },
|
||||
{ "teleport", COMPATF2_TELEPORT, SLOT_COMPAT2 },
|
||||
{ "disablepushwindowcheck", COMPATF2_PUSHWINDOW, SLOT_COMPAT2 },
|
||||
|
||||
{ NULL, 0, 0 }
|
||||
};
|
||||
|
|
|
@ -574,7 +574,7 @@ CUSTOM_CVAR(Int, compatmode, 0, CVAR_ARCHIVE|CVAR_NOINITCALL)
|
|||
|
||||
case 4: // Old ZDoom compat mode
|
||||
v = COMPATF_SOUNDTARGET | COMPATF_LIGHT;
|
||||
w = COMPATF2_MULTIEXIT | COMPATF2_TELEPORT;
|
||||
w = COMPATF2_MULTIEXIT | COMPATF2_TELEPORT | COMPATF2_PUSHWINDOW;
|
||||
break;
|
||||
|
||||
case 5: // MBF compat mode
|
||||
|
@ -631,6 +631,7 @@ CVAR (Flag, compat_soundcutoff, compatflags2, COMPATF2_SOUNDCUTOFF);
|
|||
CVAR (Flag, compat_pointonline, compatflags2, COMPATF2_POINTONLINE);
|
||||
CVAR (Flag, compat_multiexit, compatflags2, COMPATF2_MULTIEXIT);
|
||||
CVAR (Flag, compat_teleport, compatflags2, COMPATF2_TELEPORT);
|
||||
CVAR (Flag, compat_pushwindow, compatflags2, COMPATF2_PUSHWINDOW);
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
|
|
|
@ -342,7 +342,8 @@ enum : unsigned int
|
|||
COMPATF2_SOUNDCUTOFF = 1 << 2, // Cut off sounds when an actor vanishes instead of making it owner-less
|
||||
COMPATF2_POINTONLINE = 1 << 3, // Use original but buggy P_PointOnLineSide() and P_PointOnDivlineSideCompat()
|
||||
COMPATF2_MULTIEXIT = 1 << 4, // Level exit can be triggered multiple times (required by Daedalus's travel tubes, thanks to a faulty script)
|
||||
COMPATF2_TELEPORT = 1 << 5, // Don't let indirect teleports trigger sector actions
|
||||
COMPATF2_TELEPORT = 1 << 5, // Don't let indirect teleports trigger sector actions
|
||||
COMPATF2_PUSHWINDOW = 1 << 6, // Disable the window check in CheckForPushSpecial()
|
||||
};
|
||||
|
||||
// Emulate old bugs for select maps. These are not exposed by a cvar
|
||||
|
@ -356,7 +357,6 @@ enum
|
|||
BCOMPATF_BADPORTALS = 1 << 4, // Restores the old unstable portal behavior
|
||||
BCOMPATF_REBUILDNODES = 1 << 5, // Force node rebuild
|
||||
BCOMPATF_LINKFROZENPROPS = 1 << 6, // Clearing PROP_TOTALLYFROZEN or PROP_FROZEN also clears the other
|
||||
BCOMPATF_NOWINDOWCHECK = 1 << 7, // Disable the window check in CheckForPushSpecial()
|
||||
BCOMPATF_FLOATBOB = 1 << 8, // Use Hexen's original method of preventing floatbobbing items from falling down
|
||||
BCOMPATF_NOSLOPEID = 1 << 9, // disable line IDs on slopes.
|
||||
};
|
||||
|
|
|
@ -1342,6 +1342,7 @@ MapFlagHandlers[] =
|
|||
{ "compat_pointonline", MITYPE_COMPATFLAG, 0, COMPATF2_POINTONLINE },
|
||||
{ "compat_multiexit", MITYPE_COMPATFLAG, 0, COMPATF2_MULTIEXIT },
|
||||
{ "compat_teleport", MITYPE_COMPATFLAG, 0, COMPATF2_TELEPORT },
|
||||
{ "compat_pushwindow", MITYPE_COMPATFLAG, 0, COMPATF2_PUSHWINDOW },
|
||||
{ "cd_start_track", MITYPE_EATNEXT, 0, 0 },
|
||||
{ "cd_end1_track", MITYPE_EATNEXT, 0, 0 },
|
||||
{ "cd_end2_track", MITYPE_EATNEXT, 0, 0 },
|
||||
|
|
|
@ -552,21 +552,31 @@ void P_ActivateInStasisCeiling (int tag)
|
|||
//
|
||||
//============================================================================
|
||||
|
||||
bool EV_CeilingCrushStop (int tag)
|
||||
bool EV_CeilingCrushStop (int tag, bool remove)
|
||||
{
|
||||
bool rtn = false;
|
||||
DCeiling *scan;
|
||||
TThinkerIterator<DCeiling> iterator;
|
||||
|
||||
while ( (scan = iterator.Next ()) )
|
||||
scan = iterator.Next();
|
||||
while (scan != nullptr)
|
||||
{
|
||||
DCeiling *next = iterator.Next();
|
||||
if (scan->m_Tag == tag && scan->m_Direction != 0)
|
||||
{
|
||||
SN_StopSequence (scan->m_Sector, CHAN_CEILING);
|
||||
scan->m_OldDirection = scan->m_Direction;
|
||||
scan->m_Direction = 0; // in-stasis;
|
||||
if (!remove)
|
||||
{
|
||||
SN_StopSequence(scan->m_Sector, CHAN_CEILING);
|
||||
scan->m_OldDirection = scan->m_Direction;
|
||||
scan->m_Direction = 0; // in-stasis;
|
||||
}
|
||||
else
|
||||
{
|
||||
scan->Destroy();
|
||||
}
|
||||
rtn = true;
|
||||
}
|
||||
scan = next;
|
||||
}
|
||||
|
||||
return rtn;
|
||||
|
|
|
@ -689,9 +689,22 @@ FUNC(LS_Ceiling_LowerAndCrushDist)
|
|||
}
|
||||
|
||||
FUNC(LS_Ceiling_CrushStop)
|
||||
// Ceiling_CrushStop (tag)
|
||||
// Ceiling_CrushStop (tag, remove)
|
||||
{
|
||||
return EV_CeilingCrushStop (arg0);
|
||||
bool remove;
|
||||
switch (arg3)
|
||||
{
|
||||
case 1:
|
||||
remove = false;
|
||||
break;
|
||||
case 2:
|
||||
remove = true;
|
||||
break;
|
||||
default:
|
||||
remove = gameinfo.gametype == GAME_Hexen;
|
||||
break;
|
||||
}
|
||||
return EV_CeilingCrushStop (arg0, remove);
|
||||
}
|
||||
|
||||
FUNC(LS_Ceiling_CrushRaiseAndStay)
|
||||
|
@ -893,9 +906,22 @@ FUNC(LS_Plat_PerpetualRaiseLip)
|
|||
}
|
||||
|
||||
FUNC(LS_Plat_Stop)
|
||||
// Plat_Stop (tag)
|
||||
// Plat_Stop (tag, remove?)
|
||||
{
|
||||
EV_StopPlat (arg0);
|
||||
bool remove;
|
||||
switch (arg3)
|
||||
{
|
||||
case 1:
|
||||
remove = false;
|
||||
break;
|
||||
case 2:
|
||||
remove = true;
|
||||
break;
|
||||
default:
|
||||
remove = gameinfo.gametype == GAME_Hexen;
|
||||
break;
|
||||
}
|
||||
EV_StopPlat(arg0, remove);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -1912,7 +1912,7 @@ static void CheckForPushSpecial(line_t *line, int side, AActor *mobj, DVector2 *
|
|||
{
|
||||
if (line->special && !(mobj->flags6 & MF6_NOTRIGGER))
|
||||
{
|
||||
if (posforwindowcheck && !(ib_compatflags & BCOMPATF_NOWINDOWCHECK) && line->backsector != NULL)
|
||||
if (posforwindowcheck && !(i_compatflags2 & COMPATF2_PUSHWINDOW) && line->backsector != NULL)
|
||||
{ // Make sure this line actually blocks us and is not a window
|
||||
// or similar construct we are standing inside of.
|
||||
DVector3 pos = mobj->PosRelative(line);
|
||||
|
|
|
@ -429,15 +429,21 @@ void DPlat::Stop ()
|
|||
m_Status = in_stasis;
|
||||
}
|
||||
|
||||
void EV_StopPlat (int tag)
|
||||
void EV_StopPlat (int tag, bool remove)
|
||||
{
|
||||
DPlat *scan;
|
||||
TThinkerIterator<DPlat> iterator;
|
||||
|
||||
while ( (scan = iterator.Next ()) )
|
||||
scan = iterator.Next();
|
||||
while (scan != nullptr)
|
||||
{
|
||||
DPlat *next = iterator.Next();
|
||||
if (scan->m_Status != DPlat::in_stasis && scan->m_Tag == tag)
|
||||
scan->Stop ();
|
||||
{
|
||||
if (!remove) scan->Stop();
|
||||
else scan->Destroy();
|
||||
}
|
||||
scan = next;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -212,13 +212,13 @@ private:
|
|||
|
||||
friend bool EV_DoPlat (int tag, line_t *line, EPlatType type,
|
||||
double height, double speed, int delay, int lip, int change);
|
||||
friend void EV_StopPlat (int tag);
|
||||
friend void EV_StopPlat (int tag, bool remove);
|
||||
friend void P_ActivateInStasis (int tag);
|
||||
};
|
||||
|
||||
bool EV_DoPlat (int tag, line_t *line, DPlat::EPlatType type,
|
||||
double height, double speed, int delay, int lip, int change);
|
||||
void EV_StopPlat (int tag);
|
||||
void EV_StopPlat (int tag, bool remove);
|
||||
void P_ActivateInStasis (int tag);
|
||||
|
||||
//
|
||||
|
@ -434,14 +434,14 @@ private:
|
|||
DCeiling ();
|
||||
|
||||
friend bool P_CreateCeiling(sector_t *sec, DCeiling::ECeiling type, line_t *line, int tag, double speed, double speed2, double height, int crush, int silent, int change, DCeiling::ECrushMode hexencrush);
|
||||
friend bool EV_CeilingCrushStop (int tag);
|
||||
friend bool EV_CeilingCrushStop (int tag, bool remove);
|
||||
friend void P_ActivateInStasisCeiling (int tag);
|
||||
};
|
||||
|
||||
bool P_CreateCeiling(sector_t *sec, DCeiling::ECeiling type, line_t *line, int tag, double speed, double speed2, double height, int crush, int silent, int change, DCeiling::ECrushMode hexencrush);
|
||||
bool EV_DoCeiling (DCeiling::ECeiling type, line_t *line, int tag, double speed, double speed2, double height, int crush, int silent, int change, DCeiling::ECrushMode hexencrush = DCeiling::ECrushMode::crushDoom);
|
||||
|
||||
bool EV_CeilingCrushStop (int tag);
|
||||
bool EV_CeilingCrushStop (int tag, bool remove);
|
||||
void P_ActivateInStasisCeiling (int tag);
|
||||
|
||||
|
||||
|
|
|
@ -397,6 +397,7 @@ D62DCA9EC226DE49108D5DD9271F7631 // Cheogsh 2 map04
|
|||
|
||||
E89CCC7E155F1032F693359CC219BE6C // hexen.wad map30
|
||||
B9DFF13207EACAC675C71D82624D0007 // XtheaterIII map01
|
||||
6941BDC2F80C0FEBE34EFA23D5FB72B7 // sonic.wad map10
|
||||
{
|
||||
DisablePushWindowCheck
|
||||
}
|
||||
|
@ -435,6 +436,17 @@ C98F79709BD7E0E4C19026AB9575EC6F // cc-cod.zip:codlev.wad map07
|
|||
teleport
|
||||
}
|
||||
|
||||
8570AA0D6737C0A19DB66767764F157F // sonic.wad map04
|
||||
{
|
||||
noslopeid
|
||||
}
|
||||
|
||||
05AA32F1D2220A462DCDA245ED22B94B // sonic.wad map09
|
||||
{
|
||||
polyobj
|
||||
}
|
||||
|
||||
|
||||
D7F6E9F08C39A17026349A04F8C0B0BE // Return to Hadron, e1m9
|
||||
19D03FFC875589E21EDBB7AB74EF4AEF // Return to Hadron, e1m9, 2016.01.03 update
|
||||
{
|
||||
|
|
|
@ -2069,6 +2069,8 @@ CMPTMNU_SILENTINSTANTFLOORS = "Inst. moving floors are not silent";
|
|||
CMPTMNU_SECTORSOUNDS = "Sector sounds use center as source";
|
||||
CMPTMNU_SOUNDCUTOFF = "Sounds stop when actor vanishes";
|
||||
CMPTMNU_SOUNDTARGET = "Use original sound target handling";
|
||||
CMPTMNU_TELEPORT = "Scripted teleports don't trigger sector actions";
|
||||
CMPTMNU_PUSHWINDOW = "Non-blocking lines can be pushed";
|
||||
|
||||
// Sound Options
|
||||
SNDMNU_TITLE = "SOUND OPTIONS";
|
||||
|
|
|
@ -1333,6 +1333,8 @@ OptionMenu "CompatibilityOptions"
|
|||
Option "$CMPTMNU_FLOORMOVE", "compat_floormove", "YesNo"
|
||||
Option "$CMPTMNU_POINTONLINE", "compat_pointonline", "YesNo"
|
||||
Option "$CMPTMNU_MULTIEXIT", "compat_multiexit", "YesNo"
|
||||
Option "$CMPTMNU_TELEPORT", "compat_teleport", "YesNo"
|
||||
Option "$CMPTMNU_PUSHWINDOW", "compat_pushwindow", "YesNo"
|
||||
|
||||
StaticText " "
|
||||
StaticText "$CMPTMNU_PHYSICSBEHAVIOR",1
|
||||
|
|
Loading…
Reference in a new issue