Raised This Month: $ Target: $400
 0% 

HELP with menu


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
risontek22
Member
Join Date: Mar 2013
Location: localhost
Old 07-23-2013 , 03:51   HELP with menu
Reply With Quote #1

hi i have made this, but the menu doesnt show. Help pls

PHP Code:

new const MAPS[][]        = {
    
"de_dust2",
    
"de_dust",
    
"de_aztec",
    
"de_nuke",
    
"de_inferno",
    
"de_italy"
}

public 
cmd_select_map(id)
{
    new 
mmenu menu_create("\rZmenit mapu","cmd_select_map_handler")

    for(new 
i<=  sizeof(MAPS); i++)
    {
        
menu_additem(mmenu,MAPS[i])
    }
    
    
menu_additem(mmenu,"\rZavriet")
    
    
menu_setprop(mmenu,MPROP_PERPAGE,0)
    
menu_setprop(mmenu,MPROP_NUMBER_COLOR,"\y")
    
    
menu_display(id,mmenu)
}

public 
cmd_select_map_handler(id,menu,item)
{
    if(
item == (sizeof(MAPS)+1))
    {
        
menu_destroy(menu)
        return 
PLUGIN_HANDLED
    
}
    
    if(!
admin[id])
        return 
PLUGIN_HANDLED

    server_cmd
("amx_map %s",MAPS[item])    
        
    return 
PLUGIN_HANDLED

risontek22 is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:22.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode