Raised This Month: $ Target: $400
 0% 

Menu within a menu


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
SuperDuper
Member
Join Date: May 2006
Location: na
Old 05-21-2006 , 23:42   Menu within a menu
Reply With Quote #1

I am doing a plugin so that when you are bored with 2 noobs running in circles trying to find each other, why not treat your self to some jokes? I need to make a menu, inside another menu and im having trouble, this is what i have so far, mind giving some tips?

Code:
#include <amxmodx> #include <amxmisc> #include <cstrike> #define PLUGIN "joke_menu" #define VERSION "1.0" #define AUTHOR "superduper" #define JokeMeMenu (1<<0)|(1<<1)|(1<<2)|(1<<3)|(1<<4)|(1<<5)|(1<<6)|(1<<7)|(1<<8) // Keys: 123456789 public plugin_init() {     register_plugin("Joke_menu","1.0","SuperDuper")         register_cvar("funny","1")     register_cvar("funnier", "500")     register_cvar("quotes", "500")     register_cvar("catchlines", "500")         register_clcmd( "joke_me","ShowJokeMeMenu")         set_task(0.1,"fast",0,"",0,"b")     g_nMsgScreenFade = get_user_msgid("ScreenFade")     } public ShowJokeMeMenu(id) {     show_menu(id, KeysJokeMeMenu, "Menu: ^n1: ^n2: ^n3:^n4:  ^n", -1, "JokeMeMenu") // Display menu } public PressedJokeMeMenu(id, key) {     /* Menu:     * Menu:     * 1:  Funny     * 2:  Funnier     * 3:  Quotes     * 4:  Catchlines     */         switch (key) {         case 0: { // 1             if(get_cvar_num("sv_JokeMe") == 0)             {                 client_print(id, print_chat, "[PFI] This Plugin Is Disabled.")                 return PLUGIN_HANDLED                 }

And thank you "Onfirenburnin420" i am using your layout.
__________________
[Team.Profit] Profit' <LDR>. Our server owns!

CS:CZ or DIE
SuperDuper is offline
Send a message via AIM to SuperDuper Send a message via MSN to SuperDuper Send a message via Yahoo to SuperDuper
Hawk552
AMX Mod X Moderator
Join Date: Aug 2005
Old 05-22-2006 , 08:37  
Reply With Quote #2

You never registered the menu. You'll either need to register 2 or do more complex coding.

Code:
register_menucmd(register_menuid(name[]),keys,function[])
__________________
Hawk552 is offline
Send a message via AIM to Hawk552
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 16:19.


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