From 7ca4dbfdeb989f63968d541ea10269dd67a5744d Mon Sep 17 00:00:00 2001 From: Riwan Mattei Date: Mon, 15 Apr 2019 22:13:36 +0200 Subject: [PATCH] Removing TimeMenuHandle references --- scripting/lbd_sbpp_main.sp | 30 ++---------------------------- 1 file changed, 2 insertions(+), 28 deletions(-) diff --git a/scripting/lbd_sbpp_main.sp b/scripting/lbd_sbpp_main.sp index 39abf22..a43f1b0 100644 --- a/scripting/lbd_sbpp_main.sp +++ b/scripting/lbd_sbpp_main.sp @@ -115,8 +115,7 @@ int Handle ConfigParser , hTopMenu = INVALID_HANDLE - , TimeMenuHandle /* Menu file globals */ - , ReasonMenuHandle + , ReasonMenuHandle /* Menu file globals */ , HackingMenuHandle , g_hFwd_OnBanAdded , g_hFwd_OnReportAdded @@ -182,12 +181,6 @@ public OnPluginStart() RegConsoleCmd("say", ChatHook); RegConsoleCmd("say_team", ChatHook); - if ((TimeMenuHandle = CreateMenu(MenuHandler_BanTimeList, MenuAction_Select|MenuAction_Cancel|MenuAction_DrawItem)) != INVALID_HANDLE) - { - SetMenuPagination(TimeMenuHandle, 8); - SetMenuExitBackButton(TimeMenuHandle, true); - } - if ((ReasonMenuHandle = CreateMenu(ReasonSelected)) != INVALID_HANDLE) { SetMenuPagination(ReasonMenuHandle, 8); @@ -987,23 +980,11 @@ stock void DisplayBanTargetMenu(int client) stock void DisplayBanTimeMenu(int client) { - #if defined DEBUG - LogToFile(logFile, "DisplayBanTimeMenu()"); - #endif - - char title[100]; - FormatEx(title, sizeof(title), "%T:", "Ban player", client); - SetMenuTitle(TimeMenuHandle, title); - - DisplayMenu(TimeMenuHandle, client, MENU_TIME_FOREVER); + } stock void ResetMenu() { - if (TimeMenuHandle != INVALID_HANDLE) - { - RemoveAllMenuItems(TimeMenuHandle); - } if (ReasonMenuHandle != INVALID_HANDLE) { @@ -2257,13 +2238,6 @@ public SMCResult:ReadConfig_KeyValue(Handle:smc, const String:key[], const Strin AddMenuItem(HackingMenuHandle, key, value); } } - case ConfigStateTime: - { - if (StringToInt(key) > -1 && TimeMenuHandle != INVALID_HANDLE) - { - AddMenuItem(TimeMenuHandle, key, value); - } - } } return SMCParse_Continue; }