From 59a1b018edf0bd22c584feeefa48807feb96524e Mon Sep 17 00:00:00 2001 From: HttrckCldHKS Date: Sat, 18 Oct 2014 10:34:03 -0700 Subject: [PATCH] Improving Code --- amxmodx/meta_api.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/amxmodx/meta_api.cpp b/amxmodx/meta_api.cpp index cb973183..78ef34d6 100755 --- a/amxmodx/meta_api.cpp +++ b/amxmodx/meta_api.cpp @@ -143,13 +143,11 @@ int FF_InconsistentFile = -1; int FF_ClientAuthorized = -1; int FF_ChangeLevel = -1; -static const bool ColoredMenus(String & ModName) +bool ColoredMenus(String & ModName) { - static const char * pModNames[] = { "cstrike", "czero", "dmc", "dod", "tfc", "valve" }; - static const size_t ModsCount = sizeof(pModNames) / sizeof(const char *); - static int Iterator = 0u; + const char * pModNames[] = { "cstrike", "czero", "dmc", "dod", "tfc", "valve" }; - for (Iterator = 0u; Iterator < ModsCount; ++Iterator) + for (int Iterator = 0u; Iterator < sizeof(pModNames) / sizeof(const char *); ++Iterator) { if (ModName.compare(pModNames[Iterator]) == 0u) return true; // this game modification currently supports colored menus