Raised This Month: $ Target: $400
 0% 

survivor @ roudend.


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
One
Veteran Member
Join Date: Oct 2008
Location: Hardstyle-eSports.de
Old 10-15-2009 , 10:52   Re: survivor @ roudend.
Reply With Quote #7

i had the same idea but how you say, this can be a mini problem.

i want to check survivor/s @ round end and set 1 T to ct for new round ( if there are < 10 players) or set 2 Ts to CT when there are more then 10 players.

thats what i wanted to do :

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

#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_logevent("round_end"2"1=Round_End")
}
public 
round_end()
{
    new 
survived_players
    
new p_playernum;
    
p_playernum get_playersnum(1);
    
    for ( new 
iiNumi++ )
    {
        if(
is_user_alive(i))
        {
            
survived_players++
        }
    }
    if(
survived_players >= && p_playernum 10)
    {
        
//set 1 T to CT
    
}
    else if(
survived_players >= && p_playernum 10)
    {
        
//set 2 T's to CT
    
}

i think this code is correct but i want to know if is there a better way to do this or not? or maybe is my code not correct ?
__________________
One is offline
Send a message via ICQ to One Send a message via AIM to One Send a message via MSN to One Send a message via Yahoo to One Send a message via Skype™ to One
 



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 22:43.


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