- Enforce CheckCheatmode() for cheat-enforced CVARs, allowing them to be changed in normal single player games

This commit is contained in:
Rachael Alexanderson 2018-12-04 16:46:53 -05:00 committed by Christoph Oelckers
parent 33db5792b4
commit 0d891b6289

View file

@ -1760,11 +1760,8 @@ EXTERN_CVAR(Bool, sv_cheats);
void FBaseCVar::CmdSet (const char *newval)
{
if ((GetFlags() & CVAR_CHEAT) && !sv_cheats)
{
Printf("sv_cheats must be true to set this console variable.\n");
if ((GetFlags() & CVAR_CHEAT) && CheckCheatmode ())
return;
}
MarkUnsafe();