SA-MP Forums Archive
Team Spawns - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Team Spawns (/showthread.php?tid=115267)



Team Spawns - juuleman - 23.12.2009

Hey all,
I have a question:

What is the 'if' for giving teams other spawns like:

if playeristeam_vagos
{
SetPlayerPosition blablabla
etc...
}

Does someone know what is the 'if' code for that?

SancheZ


Re: Team Spawns - JoeDaDude - 23.12.2009

Like this?

pawn Code:
if(GetPlayerTeam(playerid) == 1)



Re: Team Spawns - juuleman - 23.12.2009

No, i mean like. If player is Team_Vagos he will spawn somewhere and Team_Grove somewhere else.

Like i seth something like:

If Player is Team_Vagos
{
SetPlayerPos
}


Like that


Re: Team Spawns - Ironboy500 - 23.12.2009

//Under OnPlayerSpawn
Code:
if(gTeam[playerid] == TEAM_BEACH) 
{
   SetPlayerPos (playerid, x, y, z);
}
else...



Re: Team Spawns - juuleman - 23.12.2009

Quote:
Originally Posted by Ironboy500
//Under OnPlayerSpawn
Code:
if(gTeam[playerid] == TEAM_BEACH) 
{
   SetPlayerPos (playerid, x, y, z);
}
else...
Getting this error:

Code:
P:\EastCoast Real Life ServeR\EastCoast Real Life ServeR\penls0.2\penls0.2\penls0.2\penls0.2\penls0.2\samp03asvr_win32\gamemodes\Ec-rls.pwn(3043) : error 010: invalid function or declaration



Re: Team Spawns - Ironboy500 - 23.12.2009

this else... means you need to continue like I did by adding more Teams Spawns.


Re: Team Spawns - juuleman - 23.12.2009

Thanks, i already found the problem..!

SancheZ


Re: Team Spawns - Ironboy500 - 23.12.2009

np