AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Look This... Help (https://forums.alliedmods.net/showthread.php?t=113586)

MouseSplash! 12-28-2009 09:53

Look This... Help
 
Hello toy doing a book-keeper(meter), I need that it(he,she) detects the last terrorist and a message goes out for him(her) with the remaining time of 20 seconds.

For the present I have this that consegui with the zp the countdown alquien can help me...


Sorry I Use Google Traducer xD


PHP Code:

#define VERSION "1.0"
#define AUTHOR "Mr.Apple"

new Restante
new Tiempo
new g_iMaxPlayers

public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_event("HLTV""event_round_start""a""1=0""2=0")
    
g_iMaxPlayers get_maxplayers()
}

public 
event_round_start()
{
    
set_task(4.0"Restante1")
    
Time 20
    Rest 
19
}

public 
Restante1()
{    
    new 
ctCounttrCount;
        
    for (new 
1<= g_iMaxPlayersi++)
    {
        if (!
is_user_alive(i))
        {
            continue;
        }
            
        switch (
cs_get_user_team(i))
        {
            case 
CS_TEAM_CT:
            {
                
ctCount++;
            }
                
            case 
CS_TEAM_T:
            {
                
trCount++;
            }
        }
    }
        
    if (
trCount 1)
    {
        return 
PLUGIN_HANDLED;
    }

    if (
ctCount == 0)
    {
        return 
PLUGIN_HANDLED;
    }
    
    
Rest--
        
    
set_hudmessage(17900, -1.00.2820.021.00.010.110); 
    
show_hudmessage(0"%i"Time); 
    --
Time;
        
    if(
Time >= 1)
    {
    
set_task(1.0"Restante1")
    }
    return 
PLUGIN_HANDLED



fysiks 12-28-2009 16:46

Re: Look This... Help
 
Quote:

Originally Posted by MouseSplash! (Post 1033848)
Sorry I Use Google Traducer xD

Fail.

Doc-Holiday 12-28-2009 17:20

Re: Look This... Help
 
Quote:

Originally Posted by fysiks (Post 1034377)

LOL gotta love the language barrier.


All times are GMT -4. The time now is 04:11.

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