Raised This Month: $ Target: $400
 0% 

Handle Menu


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Leon M.
Senior Member
Join Date: Apr 2009
Location: Germany
Old 04-19-2013 , 08:48   Re: Handle Menu
Reply With Quote #1

Something like this???

PHP Code:
public show_my_menu(id){
    new 
MenuKeysMenuBody[512]

    
add(MenuBody511"\rMy Menu\w^n^n")
    
add(MenuBody511"1. 1st option^n")
    
add(MenuBody511"2. 2nd option^n")
    
add(MenuBody511"0. Exit")

    
MenuKeys |= MENU_KEY_1 MENU_KEY_2 MENU_KEY_0
    show_menu
(idMenuKeysMenuBody, -1"My Menu")

    return 
PLUGIN_HANDLED
}

public 
action_my_menu(idkey){
    new 
iSelected key 1
    
switch(iSelected){
        case 
1: {
            
// do something
            
show_my_menu(id)
        }
        case 
2: {
            
// do something
            
show_my_menu(id)
        }
    }
    return 
PLUGIN_HANDLED

__________________
  • ZapTic - Paintball (Version 7.1.3 b1303)
  • Your #1 CS Paintball Server since 2008
  • 85.131.163.101:27015

Last edited by Leon M.; 04-19-2013 at 08:50.
Leon M. is offline
Reply



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 10:50.


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