Raised This Month: $ Target: $400
 0% 

Time limit on script


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
CarbonDioxide
Member
Join Date: Apr 2012
Old 04-25-2012 , 16:26   Time limit on script
Reply With Quote #1

Hello all,
I have this code which is supposed to modify the bcm plugin so its xpblock gives xp every 6 mins, but the problem is the script I have now gives xp multiple times per second, which is a problem!
This is the script:
PHP Code:
ActionXPBlock(ident)  
{  
    if ( 
cs_get_user_team(id) == CS_TEAM_T )  
    {  
        if ( !
g_xpblock_used[id] )  
        {  
            new 
property[5];  
            
GetProperty(ent1property);  
            
hnsxp_add_user_xp(idstr_to_num(property));  
            
g_xpblock_used[id] = true;  
              
            
set_hudmessage(025500.010.1800.01.00.250.252);  
            
show_hudmessage(id"You got %i more XP!"str_to_num(property));  
        }  
    }  
        else  
        {  
            
set_hudmessage(025500.010.1800.01.00.250.252);  
            
show_hudmessage(id"Only Terrorists can take XP Block!");  
    }  

If someone could add a time limit of 360 secs, or even guide me so I do it myself(even though I do not know a lot of scripting..), I would really appreciate it.. : )

Keep up the good work,
CarbonDioxide
CarbonDioxide 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 07:49.


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