From 948bf27a68750aa4872faf0272d7132672394e7c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9lio=20Lozatto=20Baniuk?= Date: Wed, 17 Jan 2024 15:51:22 -0300 Subject: [PATCH] Update map_manager_nomination.sma --- .../addons/amxmodx/scripting/map_manager_nomination.sma | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/cstrike/addons/amxmodx/scripting/map_manager_nomination.sma b/cstrike/addons/amxmodx/scripting/map_manager_nomination.sma index ac4bafb..1641cb9 100644 --- a/cstrike/addons/amxmodx/scripting/map_manager_nomination.sma +++ b/cstrike/addons/amxmodx/scripting/map_manager_nomination.sma @@ -451,6 +451,9 @@ public lists_handler(id, menu, item) } show_nomination_menu(id, Array:maplist, custom_title[] = "") { + if(!is_user_connected(id)) + return; + new text[64]; if(!custom_title[0]) { formatex(text, charsmax(text), "%L", LANG_PLAYER, "MAPM_MENU_MAP_LIST"); @@ -520,11 +523,17 @@ bool:in_array(Array:array, index) } public mapslist_handler(id, menu, item) { + if(!is_user_connected(id)) { + menu_destroy(menu); + return PLUGIN_HANDLED; + } + if(item == MENU_EXIT) { menu_destroy(menu); return PLUGIN_HANDLED; } + new item_info[8], item_name[MAPNAME_LENGTH + 16], access, callback; menu_item_getinfo(menu, item, access, item_info, charsmax(item_info), item_name, charsmax(item_name), callback);