Raised This Month: $ Target: $400
 0% 

menu_display doesn't works good


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
#8 SickneSS
BANNED
Join Date: Sep 2008
Location: Here
Old 08-17-2010 , 12:47   Re: menu_display doesn't works good
Reply With Quote #3

PHP Code:
public ChatMenuPlayers(id)
{
    new 
menu menu_create("\r[AMXX]\y Chat Mute :","ChatMenu_Handler")
    
    static 
temp[256]
    static 
name[32]
    static 
item[32]
    
    for(new 
1;<= MaxPlayers;i++)
    {
        if(
== id || !is_user_connected(i)) continue;
        
/*|| !is_user_bot(i) || !is_user_hltv(i))*/ 
            
        
get_user_name(i,name,31)
        
num_to_str(i,item,31)
            
        
formatex(temp,255,"%s \y%s\y%s",name,vMuted[id][i] ? "(Voz)" "",cMuted[id][i] ? "(Chat)" "")
        
menu_additem(menu,temp,item)
    }
    
    
menu_display(id,menu)

}
public 
ChatMenu_Handler(id,menu,item)
{
    if(
item == MENU_EXIT)
    {
        
menu_destroy(menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
iData[6]
    new 
iName[64]
    new 
Access
    
new Callback
    menu_item_getinfo
(menu,item,Access,iData,5,iName,63,Callback)
    
    new 
Target str_to_num(iData)
    
    switch(
Target)
    {
        case 
MenuPage[id]--
        case 
MenuPage[id]++
        
        default : 
cMuted[id][Target] = !cMuted[id][Target]
    }
    
menu_display(id,menu,MenuPage[id])
    return 
PLUGIN_HANDLED


Last edited by #8 SickneSS; 08-17-2010 at 13:05.
#8 SickneSS is offline
Send a message via MSN to #8 SickneSS Send a message via Skype™ to #8 SickneSS
 



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 21:52.


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