From 88c442514ad51af600206ef48997327fc87ca5cf Mon Sep 17 00:00:00 2001 From: Phillip Stephens Date: Wed, 2 Dec 2015 20:08:14 -0800 Subject: [PATCH] Only deserialize CVar value when they differ --- hecl/lib/CVarManager.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/hecl/lib/CVarManager.cpp b/hecl/lib/CVarManager.cpp index 4f4fb7d4e..cdfd634a5 100755 --- a/hecl/lib/CVarManager.cpp +++ b/hecl/lib/CVarManager.cpp @@ -123,8 +123,11 @@ void CVarManager::deserialize(CVar* cvar) return; } - cvar->m_value = tmp.m_value; - cvar->m_flags |= CVar::EFlags::Modified; + if (cvar->m_value != tmp.m_value) + { + cvar->m_value = tmp.m_value; + cvar->m_flags |= CVar::EFlags::Modified; + } } } }