Assigned Character Script (or whatever it's called) - 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: Assigned Character Script (or whatever it's called) (
/showthread.php?tid=67597)
Assigned Character Script (or whatever it's called) -
Puzi - 02.03.2009
Hi, I have a question. Everybody keeps choosing characters they want, and my serv is a RPG one. Of course, You should have a job to be able to choose this character. My question is how to assign chosen people to one character? Hope you get my question, and can answer
Regards
Puzi
Re: Assigned Character Script (or whatever it's called) -
ICECOLDKILLAK8 - 02.03.2009
OnPlayerSpawn, SetPlayerSkin
Re: Assigned Character Script (or whatever it's called) -
Puzi - 02.03.2009
Can i get more detail plz?
![Smiley](images/smilies/smile.png)
I'm a newbie, so im not sure...Do you have to add to those lines %s ? Or what do you have to include to it?
Re: Assigned Character Script (or whatever it's called) -
pspleo - 02.03.2009
pawn Code:
public OnPlayerSpawn(playerid)
{
if(job == job) //do whatever job you want
{
SetPlayerSkin(playerid, skinid);
}
}
Good list of skins:
http://www.gtam.info/sampid/skiny_samp.php
Re: Assigned Character Script (or whatever it's called) -
Puzi - 02.03.2009
Oh, been on that website, but thx for link anyway. Hope that command works. First I gotta understand what's for what xD
Re: Assigned Character Script (or whatever it's called) -
Puzi - 02.03.2009
Code:
public OnPlayerSpawn(playerid) //Ten Public Odpowiada za Spawn
{
return 1;
}
forward SetPlayerRandomSpawn(playerid);
public SetPlayerRandomSpawn(playerid)
{
new rand = random(sizeof(Spawny));
SetPlayerPos(playerid, Spawny[rand][0], Spawny[rand][1], Spawny[rand][2]); //
SetPlayerFacingAngle(playerid, 88.0);
return 1;
}
I have those lines, because script was made by someone else (my good friend SpeeD
![Cheesy](images/smilies/biggrin.png)
). Anyway, where do I insert those lines you gave me?