Problem with GetPlayerWantedLevel and GetPlayerTeam or OnPlayerUpdate
#1

Код:
public OnPlayerUpdate(playerid)
	{
	GetPlayerPos(playerid, UpdateX, UpdateY, UpdateZ);
	if(GetPlayerWantedLevel(playerid)>0&&GetPlayerTeam(playerid)==TEAM_CIV)
		{
		print("is wanted and civ");
		for(new i = 0; i < GetMaxPlayers(); i++)
		{
			if(GetPlayerTeam(i)==TEAM_COP)
				{
				print("is cop somewhere");
				if(PlayerToPoint(2, i, UpdateX, UpdateY, UpdateZ))
					{
					print("someone busted");
					SpawnPlayer(playerid);
					ResetPlayerWeapons(playerid);
					SetPlayerHealth(playerid, 100);
					SetPlayerPos(playerid, -2631.6670, 1360.6400, 7.1086);
					}
				}
			}
		}
	return 1;
	}
Even
Код:
print("is wanted and civ");
is not called, but the TEAM_CIV is set on spawn and i set my TEAM_COP with a command but i don't know why it's not working.
Reply


Messages In This Thread
Problem with GetPlayerWantedLevel and GetPlayerTeam or OnPlayerUpdate - by ronyx69 - 17.08.2009, 12:34
Re: Problem with GetPlayerWantedLevel and GetPlayerTeam or OnPlayerUpdate - by kc - 17.08.2009, 12:58
Re: Problem with GetPlayerWantedLevel and GetPlayerTeam or OnPlayerUpdate - by dice7 - 17.08.2009, 12:58
Re: Problem with GetPlayerWantedLevel and GetPlayerTeam or OnPlayerUpdate - by ronyx69 - 17.08.2009, 16:49

Forum Jump:


Users browsing this thread: 1 Guest(s)