Raised This Month: $ Target: $400
 0% 

Error 008 : Please help !


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 03-11-2017 , 16:06   Re: Error 008 : Please help !
Reply With Quote #1

As the error says, you cannot use non-constants in a switch.

Think about the logic behind the rule. When you set up a switch, you want react a particular way for a list of possible values. If you allow dynamic values as a case in the switch, you cannot execute a scenario on the value consistently.

Should you may be doing this? I do not know enough about your code works to give you an educated answer.
PHP Code:
    switch ( g_iAdrenalineInUse )
    {
        case 
SPEED:
        {

        }
    } 
__________________

Last edited by Bugsy; 03-11-2017 at 16:08.
Bugsy is offline
ish12321
Veteran Member
Join Date: May 2016
Old 03-11-2017 , 16:42   Re: Error 008 : Please help !
Reply With Quote #2

nope I need to check for the value I put in switch only as I do something like this too

PHP Code:
    for(new CAMOUFLAGE<= GOD_MODEi++)
    {
        
g_iADR_HOOKS[i]    =    jctf_add_adrenaline_item(g_iADR_TITLE_ML[i], g_iADR_DESC_ML[i], g_iADRCosts[i], g_iADRDrain[i], g_iADR_ITEMS_EOD[i], g_iADR_ITEM_VIP_ONLY[i]);
    } 
__________________
['O|s|G'] | Death Wins a.k.a Ish Chhabra was here
ish12321 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 18:02.


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