Permalink
Browse files

Also ensure Cvar::ROM cvars are reset

  • Loading branch information...
DolceTriade committed Dec 24, 2015
1 parent 0146ad6 commit c812e459d9165cdc8c3d2cb22c67f95205bd92fb
Showing with 1 addition and 7 deletions.
  1. +1 −7 daemon/src/engine/framework/CvarSystem.cpp
@@ -306,19 +306,13 @@ namespace Cvar {
cvar->flags &= ~CVAR_USER_CREATED;
cvar->flags |= flags;
cvar->proxy = proxy;
if (flags & CHEAT) {
if (flags & (CHEAT | ROM)) {
cvar->value = defaultValue;
}

cvar->resetValue = defaultValue;
cvar->description = "";

/*
if (cvar->flags & CVAR_ROM) {
cvar->value = cvar->resetValue;
}
*/

if (proxy) { //TODO replace me with an assert once we do not need to support the C API
OnValueChangedResult result = proxy->OnValueChanged(cvar->value);
if (result.success) {

0 comments on commit c812e45

Please sign in to comment.