diff --git a/extensions/tf2/conditions.cpp b/extensions/tf2/conditions.cpp index 95b55756..d298df4e 100644 --- a/extensions/tf2/conditions.cpp +++ b/extensions/tf2/conditions.cpp @@ -159,7 +159,7 @@ void PlayerConditionsMgr::Shutdown() void PlayerConditionsMgr::OnClientPutInServer(int client) { - memset(&m_OldConds[client], 0, CondVar_Count * sizeof(int)); + memset(&m_OldConds[client], 0, sizeof(m_OldConds[0])); } PlayerConditionsMgr g_CondMgr; \ No newline at end of file diff --git a/extensions/tf2/conditions.h b/extensions/tf2/conditions.h index 6ae42e6f..76193c13 100644 --- a/extensions/tf2/conditions.h +++ b/extensions/tf2/conditions.h @@ -68,9 +68,9 @@ private: template bool SetupProp(const char *varname); private: - int m_OldConds[TF_MAXPLAYERS + 1][CondVar_Count]; + int m_OldConds[SM_MAXPLAYERS + 1][CondVar_LastNotifyProp]; sm_sendprop_info_t m_CondVarProps[CondVar_Count]; - SendVarProxyFn m_BackupProxyFns[CondVar_Count]; + SendVarProxyFn m_BackupProxyFns[CondVar_LastNotifyProp]; }; extern PlayerConditionsMgr g_CondMgr; diff --git a/extensions/tf2/extension.h b/extensions/tf2/extension.h index 535af282..d9b22334 100644 --- a/extensions/tf2/extension.h +++ b/extensions/tf2/extension.h @@ -42,8 +42,6 @@ #include #include -const int TF_MAXPLAYERS = 33; - namespace SourceMod { class ISDKTools; }