Raised This Month: $ Target: $400
 0% 

please help me about MenuAction_Select


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
lovemf
BANNED
Join Date: May 2009
Old 07-31-2009 , 08:27   Re: please help me about MenuAction_Select
Reply With Quote #1

i found

Code:
 if (action == MenuAction_VoteEnd)
can get 'param2' forever.

i do this

Code:
public Help_CustomMenuHandler(Handle:menu, MenuAction:action, param1, param2) 
{
 // MapMenuHandler(menu, MenuAction_Select, 0, param1);
 
 if (action == MenuAction_End) 
 {
  CloseHandle(menu);
 } 
 else if (action == MenuAction_Select) {
 new String:itemval[256];
 new String:typetext[256];
 decl String:display[256];
 GetMenuItem(menu, param2, itemval, sizeof(itemval), _, display, sizeof(display));
 GetMenuItem(menu, param2, "", 0, _, typetext, sizeof(typetext));
 PrintToChatAll("\x04[%N] \x03 command:%s   typetext:%s",param1,itemval,typetext);
 
 // MapMenuHandler(menu, MenuAction_Select, 0, param1);
 }
 else if (action == MenuAction_VoteEnd)
 {
 
 new String:itemval[256];
 new String:typetext[256];
 decl String:display[256];
 GetMenuItem(menu, param2, itemval, sizeof(itemval), _, display, sizeof(display));
 GetMenuItem(menu, param2, "", 0, _, typetext, sizeof(typetext));
 PrintToChatAll("\x04[%N] \x03 command:%s   typetext:%s",param1,itemval,typetext);
 
 MapMenuHandler(menu, MenuAction_Select, 0, param1);
 new Handle:dp;
 CreateDataTimer(5.0, Timer_run, dp);
 WritePackString(dp, itemval); 
 
 }
}
public MapMenuHandler(Handle:menu, MenuAction:action, client, itemNum)
{
PrintToChatAll("\x04[%i",itemNum);
}
this value is "1" forever.

Last edited by lovemf; 07-31-2009 at 08:34.
lovemf is offline
Reply


Thread Tools
Display Modes

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 19:05.


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