Whats wrong with this Auto Balance
#5

Quote:
Originally Posted by Bakr
Посмотреть сообщение
Do you set the player's teams during OnPlayerRequestClass? If not, that would be your problem, as their team would still be equal to NO_TEAM.

Under OnPlayerRequestClass, compare their classid with the skin they are one, and set their team there. Then your script will work.
i made this
is that right
Код:
public OnPlayerRequestClass(playerid, classid)
{
	SetPlayerPos(playerid, 1380.6447,-1753.0427,13.5469);
    SetPlayerFacingAngle(playerid, 269.6420);
    SetPlayerCameraPos(playerid, 1387.2906,-1752.8887,13.3828);
    SetPlayerCameraLookAt(playerid, 1380.6447,-1753.0427,13.5469);

    if(classid == 0)
	{
		GameTextForPlayer(playerid,"~r~Terorist",6000,6);
		gTeam[playerid] = TEAM_RED;
		SetPlayerTeam(playerid, 0);
	}
 	if(classid == 1)
	 {
		GameTextForPlayer(playerid,"~b~Counter Terorist",6000,6);
		gTeam[playerid] = TEAM_BLUE;
		SetPlayerTeam(playerid, 1);
	}
	return 1;
}
Reply


Messages In This Thread
Whats wrong with this Auto Balance - by handerson - 05.07.2011, 04:29
Re: Whats wrong with this Auto Balance - by Bakr - 05.07.2011, 04:32
Re: Whats wrong with this Auto Balance - by handerson - 05.07.2011, 04:45
Re: Whats wrong with this Auto Balance - by Bakr - 05.07.2011, 04:48
Re: Whats wrong with this Auto Balance - by handerson - 05.07.2011, 05:18
Re: Whats wrong with this Auto Balance - by Bakr - 05.07.2011, 05:36

Forum Jump:


Users browsing this thread: 2 Guest(s)