Raised This Month: $ Target: $400
 0% 

CountDown...


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Backstabnoob
BANNED
Join Date: Feb 2009
Location: Iwotadai Dorm
Old 05-04-2012 , 18:27   Re: CountDown...
Reply With Quote #2

PHP Code:
#include <amxmodx>
#include <amxmisc>

new Time 15;
new 
DefaultValue;

public 
plugin_init()
    
register_clcmd("say /count""CountDown");

public 
CountDown() 
{
    
    
Time 15
    set_task
1.0"_t_Countdown"999__"a"15 )
}

public 
_t_Countdowntaskid )
{
    
DefaultValue++
    
Time--
    
    if( 
Time == 
    {
        
Time DefaultValue
        DefaultValue 
0
        
        
return
    }
    
    
client_print(0print_chat"CountDown: %d"Time)

A little more optimized.
No clue what DefaultValue does do though.

Last edited by Backstabnoob; 05-04-2012 at 18:29.
Backstabnoob 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 00:23.


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