mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-23 12:32:34 +00:00
- added GZDoom's option not to count monsters in E1M8-style end of level sectors, but controlled by a dmflag.
SVN r3267 (trunk)
This commit is contained in:
parent
55bb4afac8
commit
ba661308d4
4 changed files with 21 additions and 0 deletions
|
@ -508,6 +508,7 @@ CVAR (Flag, sv_disallowsuicide, dmflags2, DF2_NOSUICIDE);
|
|||
CVAR (Flag, sv_noautoaim, dmflags2, DF2_NOAUTOAIM);
|
||||
CVAR (Flag, sv_dontcheckammo, dmflags2, DF2_DONTCHECKAMMO);
|
||||
CVAR (Flag, sv_killbossmonst, dmflags2, DF2_KILLBOSSMONST);
|
||||
CVAR (Flag, sv_nocountendmonst, dmflags2, DF2_NOCOUNTENDMONST);
|
||||
//==========================================================================
|
||||
//
|
||||
// CVAR compatflags
|
||||
|
|
|
@ -296,6 +296,7 @@ enum
|
|||
DF2_NOAUTOAIM = 1 << 23, // Players cannot use autoaim.
|
||||
DF2_DONTCHECKAMMO = 1 << 24, // Don't Check ammo when switching weapons.
|
||||
DF2_KILLBOSSMONST = 1 << 25, // Kills all monsters spawned by a boss cube when the boss dies
|
||||
DF2_NOCOUNTENDMONST = 1 << 26, // Do not count monsters in 'end level when dying' sectors towards kill count
|
||||
};
|
||||
|
||||
// [RH] Compatibility flags.
|
||||
|
|
|
@ -3928,6 +3928,24 @@ void P_SetupLevel (char *lumpname, int position)
|
|||
}
|
||||
}
|
||||
|
||||
// Don't count monsters in end-of-level sectors if option is on
|
||||
if (dmflags2 & DF2_NOCOUNTENDMONST)
|
||||
{
|
||||
TThinkerIterator<AActor> it;
|
||||
AActor * mo;
|
||||
|
||||
while ((mo=it.Next()))
|
||||
{
|
||||
if (mo->flags & MF_COUNTKILL)
|
||||
{
|
||||
if (mo->Sector->special == dDamage_End)
|
||||
{
|
||||
mo->ClearCounters();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
T_PreprocessScripts(); // preprocess FraggleScript scripts
|
||||
|
||||
// build subsector connect matrix
|
||||
|
|
|
@ -1107,6 +1107,7 @@ OptionMenu GameplayOptions
|
|||
Option "Chasecam cheat", "sv_chasecam", "YesNo"
|
||||
Option "Check ammo for weapon switch", "sv_dontcheckammo", "NoYes"
|
||||
Option "Killing Romero kills all his spawns", "sv_killbossmonst", "YesNo"
|
||||
Option "Count monsters in end level sectors", "sv_nocountendmonst", "NoYes"
|
||||
|
||||
StaticText " "
|
||||
StaticText "Deathmatch Settings",1
|
||||
|
|
Loading…
Reference in a new issue