public OnPlayerSpawn(playerid)
{
for (new i = 0, max = GetMaxPlayers(); i < max; i++)
{
if (i != playerid)
{
if (playerid's team is not the same as i's team)
{
// Make the players marker invisible to the player while keeping chat colour the same. Will only work correctly if SetPlayerColor has been used
SetPlayerMarkerForPlayer( i, playerid, ( GetPlayerColor( playerid ) & 0xFFFFFF00 ) );
ShowPlayerNameTagForPlayer(i, playerid, false);
}
}
}
return 1;
}
public OnPlayerSpawn(playerid) { SetPlayerToTeamColor(playerid); if(gTeam[playerid] == TEAM_GREEN) { GameTextForPlayer(playerid, "~b~Kill Spetznatz", 6000,5); } else if(gTeam[playerid] == TEAM_BLUE) { GameTextForPlayer(playerid, "~b~Kill USA", 6000,5); } return 0; }
public OnPlayerSpawn(playerid)
{
SetPlayerToTeamColor(playerid);
if(gTeam[playerid] == TEAM_GREEN) {
GameTextForPlayer(playerid,
"~b~Kill Spetznatz",
6000,5);
}
else if(gTeam[playerid] == TEAM_BLUE) {
GameTextForPlayer(playerid,
"~b~Kill USA",
6000,5);
}
for (new i = 0, max = GetMaxPlayers(); i < max; i++)
{
if (i != playerid)
{
if (playerid's team is not the same as i's team)
{
// Make the players marker invisible to the player while keeping chat colour the same. Will only work correctly if SetPlayerColor has been used
SetPlayerMarkerForPlayer( i, playerid, ( GetPlayerColor( playerid ) & 0xFFFFFF00 ) );
ShowPlayerNameTagForPlayer(i, playerid, false);
}
}
}
return 1;
}
return 0;
}
C:\Users\**SECRET**\Desktop\SA-MP\SA-MP 2\gamemodes\**SECRET-GM**.pwn(172) : warning 219: local variable "max" shadows a variable at a preceding level C:\Users\**SECRET**\Desktop\SA-MP\SA-MP 2\gamemodes\**SECRET-GM**.pwn(176) : error 027: invalid character constant C:\Users\**SECRET**\Desktop\SA-MP\SA-MP 2\gamemodes\**SECRET-GM**.pwn(176) : warning 215: expression has no effect C:\Users\**SECRET**\Desktop\SA-MP\SA-MP 2\gamemodes\**SECRET-GM**.pwn(176) : error 001: expected token: ";", but found "-identifier-" C:\Users\**SECRET**\Desktop\SA-MP\SA-MP 2\gamemodes\**SECRET-GM**.pwn(176) : error 017: undefined symbol "team" C:\Users\**SECRET**\Desktop\SA-MP\SA-MP 2\gamemodes\**SECRET-GM**.pwn(176) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
if (playerid's team is not the same as i's team)
Originally Posted by MadeMan
You need to edit this line:
pawn Код:
Do you use gTeam or SetPlayerTeam or something else? |