DisableMenu

DisableMenu

Description:
Function DisableMenu disable input for a menu. Any item will lose the ability to be selected.
Crashes when passed an invalid menu ID.


Parameters:
(menuid)
int menuid The ID of the menu to disable input for.


Return Values:
This function does not return any specific values.


Examples:
new WeaponMenu;
 
WeaponMenu = CreateMenu("Weapons", 1, 50.0, 180.0, 200.0, 200.0);
AddMenuItem(WeaponMenu, 0, "Rocket Launcher");
AddMenuItem(WeaponMenu, 0, "Flamethrower");
AddMenuItem(WeaponMenu, 0, "Minigun");
AddMenuItem(WeaponMenu, 0, "Grenades");
 
// Under OnPlayerCommandText
if(!strcmp(cmdtext, "/disableguns", true)) 
{
    DisableMenu(WeaponMenu); //Disable input for the weapon menu
    return 1;
}


Related Functions
The following functions may be useful, as they are related to this function in one way or another.