Raised This Month: $ Target: $400
 0% 

menu and random choose


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 03-10-2010 , 23:56   Re: menu and random choose
Reply With Quote #2

When the menu is displayed, set bool to false. When\if he selects something, set it to true.

PHP Code:
new g_bSelectedMenu;
#define CheckFlag(%1)    (g_bSelectedMenu & (1<<(%1 & 31 )))
#define SetFlag(%1)    (g_bSelectedMenu |= (1<<(%1 & 31 )))
#define RemFlag(%1)    (g_bSelectedMenu &= ~(1<<(%1 & 31 ))) 
To set the bool to false:
PHP Code:
//Set all players bool to false
g_bSelectedMenu 0;

//Set single player bool to false
RemFlagid ); 
To set the bool to true:
PHP Code:
SetFlagid ); 
Check if the bool is true:
PHP Code:
CheckFlagid ); 
__________________

Last edited by Bugsy; 03-11-2010 at 00:03.
Bugsy is offline
 



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 08:44.


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