From ab68d046c8151b2bd1a3b9424dc4fb5608e1ad14 Mon Sep 17 00:00:00 2001 From: Nick Hastings Date: Sun, 3 Jun 2018 12:36:58 -0400 Subject: [PATCH] Fix oops with SetConVarBounds. --- core/smn_console.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/core/smn_console.cpp b/core/smn_console.cpp index eea20a59..43f8ccc6 100644 --- a/core/smn_console.cpp +++ b/core/smn_console.cpp @@ -609,10 +609,12 @@ static cell_t sm_SetConVarBounds(IPluginContext *pContext, const cell_t *params) switch (params[2]) { case ConVarBound_Upper: - pConVar->m_fMaxVal = params[3] ? true : false, sp_ctof(params[4]); + pConVar->m_fMaxVal = sp_ctof(params[4]); + pConVar->m_bHasMax = params[3] ? true : false; break; case ConVarBound_Lower: - pConVar->m_fMinVal = params[3] ? true : false, sp_ctof(params[4]); + pConVar->m_fMinVal = sp_ctof(params[4]); + pConVar->m_bHasMin = params[3] ? true : false; break; default: return pContext->ThrowNativeError("Invalid ConVarBounds value %d");