OnPlayerRequestSpawn - Team Balancer
#1

Hey, i have been trying to fix my "team balancer" but it keeps being bugged.
I wont allow me to spawn.

pawn Код:
public OnPlayerRequestSpawn(playerid)
{
    if(Cmafia >= MafiaFull)
    {
        if(pi[playerid][Classid] == 1 || 2 || 3)
        {
            ForceClassSelection(playerid);
            return 0;
        }
        else
        {
            if(pi[playerid][Classid] == 1 || 2 || 3)
            {
                pi[playerid][Mafia] = 1;
            }
        }
    }
    if(Cpolice <= CopFull)
    {
        if(pi[playerid][Classid] == 4 || 5 || 6)
        {
            ForceClassSelection(playerid);
            return 0;
        }
        else
        {
            if(pi[playerid][Classid] == 4 || 5 || 6)
            {
                pi[playerid][Police] = 1;
            }
        }
    }
    return 1;
}
* pi[playerid][Classid] = classid
* CopFull/MafiaFull = 16 - Max Players per team
* Cpolice/Cmafia = players on each team
Reply


Messages In This Thread
OnPlayerRequestSpawn - Team Balancer - by Naxix - 23.11.2010, 13:57
Re: OnPlayerRequestSpawn - Team Balancer - by Vince - 23.11.2010, 14:31
Re: OnPlayerRequestSpawn - Team Balancer - by Naxix - 23.11.2010, 14:34
Re: OnPlayerRequestSpawn - Team Balancer - by Voldemort - 23.11.2010, 14:37
Re: OnPlayerRequestSpawn - Team Balancer - by Naxix - 23.11.2010, 14:40
Re: OnPlayerRequestSpawn - Team Balancer - by Voldemort - 23.11.2010, 14:43
Re: OnPlayerRequestSpawn - Team Balancer - by Naxix - 23.11.2010, 14:46
Re: OnPlayerRequestSpawn - Team Balancer - by The_Moddler - 23.11.2010, 15:49

Forum Jump:


Users browsing this thread: 2 Guest(s)