IsTeamFull
#7

PHP код:
#define MAX_PLAYERS_IN_TEAM 15
IsTeamFull(TeamID

    new 
Countbool:rt
    for(new 
=0iMAX_PLAYERSi++) 
    { 
        if(
GetPlayerTeam(i) == TeamID
        { 
            
Count++; 
        } 
    } 
    if(
Count == MAX_PLAYERS_IN_TEAM)
    { 
        return 
true;  
    }
    else return 
false;
}  
IsHightestTeam(TeamID)
{
    new 
idoutput = -1Teams[MAX_TEAMS], bool:rt;
    for(new 
=0iMAX_PLAYERSi++)
    {
        for(new 
0MAX_TEAMSk++)
        {
            if(
GetPlayerTeam(i) == k)
            {
                
Teams[k]++;
            }
        }
    }
    for (new 
htht != sizeof(Teams); ++ht)
    {
        if (
Teams[ht] > outputoutput Teams[ht], id ht;
    }
    
    if(
id == TeamID && id != -1)
    {
        return 
true;
    }
    else return 
false;

something like that ?
Reply


Messages In This Thread
IsTeamFull - by iLearner - 11.03.2017, 12:55
Re: IsTeamFull - by SyS - 11.03.2017, 13:09
Re: IsTeamFull - by TitanX - 11.03.2017, 13:10
Re: IsTeamFull - by iLearner - 11.03.2017, 13:12
Re: IsTeamFull - by TopShooter2 - 11.03.2017, 13:14
Re: IsTeamFull - by SyS - 11.03.2017, 13:22
Re: IsTeamFull - by TitanX - 11.03.2017, 13:27
Re: IsTeamFull - by SyS - 11.03.2017, 13:46
Re: IsTeamFull - by TitanX - 11.03.2017, 13:54
Re: IsTeamFull - by Trucido - 11.03.2017, 16:35

Forum Jump:


Users browsing this thread: 2 Guest(s)