Skip to content

Commit

Permalink
Update config.h
Browse files Browse the repository at this point in the history
Let cfg->Save() work after using new Clamp
  • Loading branch information
RusJJ committed Jul 20, 2023
1 parent d774d70 commit b270fa4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mod/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ class ConfigEntry
{
if(m_nIntegerValue < min)
{
m_pBoundCfg->m_bValueChanged = true;
int ret = m_nIntegerValue - min;
m_nIntegerValue = min;
m_fFloatValue = (float)min;
Expand All @@ -94,6 +95,7 @@ class ConfigEntry
}
if(m_nIntegerValue > max)
{
m_pBoundCfg->m_bValueChanged = true;
int ret = m_nIntegerValue - max;
m_nIntegerValue = max;
m_fFloatValue = (float)max;
Expand All @@ -106,6 +108,7 @@ class ConfigEntry
{
if(m_fFloatValue < min)
{
m_pBoundCfg->m_bValueChanged = true;
float ret = m_fFloatValue - min;
m_nIntegerValue = (int)min;
m_fFloatValue = min;
Expand All @@ -114,6 +117,7 @@ class ConfigEntry
}
if(m_fFloatValue > max)
{
m_pBoundCfg->m_bValueChanged = true;
float ret = m_fFloatValue - max;
m_nIntegerValue = (int)max;
m_fFloatValue = max;
Expand Down

0 comments on commit b270fa4

Please sign in to comment.