Raised This Month: $ Target: $400
 0% 

Solved Wait N amount of seconds?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
blAck.
Member
Join Date: Jun 2018
Old 08-05-2018 , 10:10   Re: Wait N amount of seconds?
Reply With Quote #1

Quote:
Originally Posted by edon1337 View Post
PHP Code:
#include < amxmodx >
#include < fun >

new g_iUseTime;

const 
g_iFreq 15;

public 
plugin_init( )
{    
    
register_clcmd"say /healme""@HealMe" );
}

@
HealMeid )
{
    new 
iTime floatroundget_gametime( ) );
    
    if( 
iTime >= g_iUseTime )
    {
        
g_iUseTime iTime g_iFreq;
        
        
set_user_healthidget_user_healthid ) + 15 );
    }
    
    else
    {
        
client_printidprint_center"You have to wait %d seconds until you can use this again."g_iUseTime iTime );
    }
    
    return 
PLUGIN_HANDLED;

This works perfectly! Ty
blAck. 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 12:37.


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