[HELP]Player Spawning Position
#1

I made 4 Teams..
USA
RUSSIA
UK
China
and for these i want different spawn points.. like if Player choose USA he should spawn in USA base and i made that
pawn Код:
if(GetPlayerTeam(playerid == TEAM_USA))
    {
       SetPlayerPos(playerid, -2026.0000,1073.0000,55.5703);
    }
    if(GetPlayerTeam(playerid == TEAM_RUSSIA))
    {
       SetPlayerPos(playerid, -1721.0000,853.0000,24.7344);
    }
    if(GetPlayerTeam(playerid == TEAM_UK))
    {
       SetPlayerPos(playerid, -1554.7438,928.7686,7.0391);
    }
    if(GetPlayerTeam(playerid == TEAM_CHINA))
    {
       SetPlayerPos(playerid, -1347.7363,504.7618,18.2344);
    }
The problem is that even if i select China Uk or Russia it spawns me at USA base... any help would be Apriciated.
Reply
#2

pawn Код:
if(GetPlayerTeam(playerid) == TEAM_USA)
    {
       SetPlayerPos(playerid, -2026.0000,1073.0000,55.5703);
       return 1;
    }
    if(GetPlayerTeam(playerid) == TEAM_RUSSIA)
       return 1;
    {
       SetPlayerPos(playerid, -1721.0000,853.0000,24.7344);
       return 1;
    }
    if(GetPlayerTeam(playerid) == TEAM_UK)
    {
       SetPlayerPos(playerid, -1554.7438,928.7686,7.0391);
       return 1;
    }
    if(GetPlayerTeam(playerid ) == TEAM_CHINA)
    {
       SetPlayerPos(playerid, -1347.7363,504.7618,18.2344);
       return 1;
    }
}
Reply
#3

Quote:
Originally Posted by Jarnu
Посмотреть сообщение
I made 4 Teams..
USA
RUSSIA
UK
China
and for these i want different spawn points.. like if Player choose USA he should spawn in USA base and i made that
pawn Код:
if(GetPlayerTeam(playerid == TEAM_USA))
    {
       SetPlayerPos(playerid, -2026.0000,1073.0000,55.5703);
    }
    if(GetPlayerTeam(playerid == TEAM_RUSSIA))
    {
       SetPlayerPos(playerid, -1721.0000,853.0000,24.7344);
    }
    if(GetPlayerTeam(playerid == TEAM_UK))
    {
       SetPlayerPos(playerid, -1554.7438,928.7686,7.0391);
    }
    if(GetPlayerTeam(playerid == TEAM_CHINA))
    {
       SetPlayerPos(playerid, -1347.7363,504.7618,18.2344);
    }
The problem is that even if i select China Uk or Russia it spawns me at USA base... any help would be Apriciated.
Fixed the ()
pawn Код:
if(GetPlayerTeam(playerid) == TEAM_USA)
    {
       SetPlayerPos(playerid, -2026.0000,1073.0000,55.5703);
    }
    if(GetPlayerTeam(playerid) == TEAM_RUSSIA)
    {
       SetPlayerPos(playerid, -1721.0000,853.0000,24.7344);
    }
    if(GetPlayerTeam(playerid) == TEAM_UK)
    {
       SetPlayerPos(playerid, -1554.7438,928.7686,7.0391);
    }
    if(GetPlayerTeam(playerid) == TEAM_CHINA)
    {
       SetPlayerPos(playerid, -1347.7363,504.7618,18.2344);
    }
Reply
#4

lol.. thanks. i always forget to add most important things when confused.

Thank you Very Much!
Reply
#5

pawn Код:
if(GetPlayerTeam(playerid) == TEAM_USA)
    {
       SetPlayerPos(playerid, -2026.0000,1073.0000,55.5703);
       return 1;
    }
    if(GetPlayerTeam(playerid) == TEAM_RUSSIA)
       return 1;
    {
       SetPlayerPos(playerid, -1721.0000,853.0000,24.7344);
       return 1;
    }
    if(GetPlayerTeam(playerid) == TEAM_UK)
    {
       SetPlayerPos(playerid, -1554.7438,928.7686,7.0391);
       return 1;
    }
    if(GetPlayerTeam(playerid ) == TEAM_CHINA)
    {
       SetPlayerPos(playerid, -1347.7363,504.7618,18.2344);
       return 1;
    }
}
Reply
#6

You are Late Sir! and i think you shouldn't Copy others Pawno Code.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)