SA-MP Forums Archive
Hello :) I need help with multiple 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: Hello :) I need help with multiple spawns.. (/showthread.php?tid=260746)



Hello :) I need help with multiple spawns.. - trapped1 - 10.06.2011

So the problem is.. I have 18 gangs I need for each gang spown point.. I have cords all things but how to make it? Plaese some one help ... It's just making me sick....


Re: Hello :) I need help with multiple spawns.. - Aoi_Rikuto - 10.06.2011

Are the gangs classes? If they're classes you can make it so on spawn, it checks the class. If the class is found it looks for the coordinates to spawn the person at.


Re: Hello :) I need help with multiple spawns.. - trapped1 - 10.06.2011

no sorry didn't make it by gang classes, now I'm looking for some information thanks for your reply


Re: Hello :) I need help with multiple spawns.. - trapped1 - 10.06.2011

just with no resulte becouse I didn't get how to set it..... or just I'm stupid but yeah... no tutorials about it... please some one help me out.. :P sorry for doble post... just network lagged


Re: Hello :) I need help with multiple spawns.. - Sascha - 10.06.2011

you should share a few more information about how it should work with us lol..
from what I just understood you can try it line that:
pawn Код:
public OnPlayerSpawn(playerid)
{
  if(gTeam[playerid] == 1)
  {
    SetPlayerPos(playerid, x, y, z);
  }
  else if(gTeam[playerid] == 2)
  {
    SetPlayerPos(playerid, x, y, z);
  }
  else if(gTeam[playerid] == 3)
  {
    SetPlayerPos(playerid, x, y, z);
  }
//etc
  return 1;
get sure to replace the x y z and the "gTeam" to your actual variables.


Re: Hello :) I need help with multiple spawns.. - trapped1 - 10.06.2011

thank you very much mate.. for your answer and your time


Respuesta: Hello :) I need help with multiple spawns.. - PiCu - 11.06.2011

new Float:PlayerRandomSpawn[11][11] = {
{1,1,1,1}, //example
{1,1,1,1,1},
{2121.4531,1403.1952,11.1328}

};
public OnPlayerSpawn()
{
SetPlayerRandomSpawn(playerid);
return 1;
}

Im New In samp and in englis sorry xD


Re: Respuesta: Hello :) I need help with multiple spawns.. - Sascha - 11.06.2011

Quote:
Originally Posted by PiCu
Посмотреть сообщение
new Float:PlayerRandomSpawn[11][11] = {
{1,1,1,1}, //example
{1,1,1,1,1},
{2121.4531,1403.1952,11.1328}

};
public OnPlayerSpawn()
{
SetPlayerRandomSpawn(playerid);
return 1;
}

Im New In samp and in englis sorry xD
first of all an advice: put your code pieces into "[pawn]" brackets^^
secondly: there is no default function "SetPlayerRandomSpawn(playerid);
and thirdly: you don't need [11][11].. either use [3][4] or [][4]
oh and: why do you reply a wrong solution to a solved topic? (<< no answer required)


Re: Hello :) I need help with multiple spawns.. - DRIFT_HUNTER - 11.06.2011

What variable you use to detect player gang?


Re: Hello :) I need help with multiple spawns.. - trapped1 - 11.06.2011

http://pastebin.com/78jCJf3u here is my script.. but only problem now is I'm spawning under map.. how to fix that prob.. the cords are good...