Raised This Month: $ Target: $400
 0% 

menu help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 10-31-2009 , 21:51   menu help
Reply With Quote #1

Using the new style menus

I can instead of using cl cmds to bring up the menu i can do something like


PHP Code:
public PlayerSpawn(id)
{
     
set_task(0.5"menu"id)

That would do it on player spawn right?

Also is there away to see if a user has a secondary weapon?
Doc-Holiday is offline
Alucard^
AMXX Moderator: Others
Join Date: Sep 2007
Location: Street
Old 10-31-2009 , 22:03   Re: menu help
Reply With Quote #2

Code:
#include <amxmodx> #define PLUGIN    "New Plugin" #define AUTHOR    "Alucard" #define VERSION    "1.0" new Menu public plugin_init() {     register_plugin(PLUGIN, VERSION, AUTHOR)         RegisterHam(Ham_Spawn, "player", "HookSpawnPL", 1)         Menu = menu_create("\ySomething here?", "HandleSpawnMenu")         menu_additem(Menu, "\wYes", "1", 0)     menu_additem(Menu, "\wNo", "2", 0)         menu_setprop(Menu, MPROP_EXIT, MEXIT_NEVER) } public HookSpawnPL(id) {     menu_display(id, Menu) } public HandleSpawnMenu(id, Menu, item) {     new iData[6]     new iAccess     new iCallback     new iName[64]         menu_item_getinfo(Menu, item, iAccess, iData, 5, iName, 63, iCallback)         switch(str_to_num(iData) )     {         case 1:         {             // Oh no!! you pressed 'Yes'         }         case 2:         {             // Oh no!! you pressed 'No'         }     }     return PLUGIN_HANDLED }
__________________
Approved Plugins - Steam Profile

Public non-terminated projects:
All Admins Menu, HLTV parameters, Subnick,
Second Password (cool style), InfoZone,
Binary C4 plant/defuse, and more...

Private projects:
NoSpec (+menu), NV Surf Management,
PM Adanved System, KZ longjump2, and more...
Alucard^ is offline
Send a message via Skype™ to Alucard^
Old 10-31-2009, 22:14
Hx7r
This message has been deleted by Hx7r.
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 10-31-2009 , 22:17   Re: menu help
Reply With Quote #4

Quote:
Originally Posted by Hx7r View Post
#include <hamsandwich>

LOL yeah i got that part...

Is there a way to get if player Hassecond like HasPrim
Doc-Holiday 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 17:48.


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