Random Teamcolor - 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: Random Teamcolor (
/showthread.php?tid=71879)
Random Teamcolor -
Mr. M - 04.04.2009
How do i set it, that when a player spawns, he gets a random color like first he gets green, and on the next join his name is purple.
I've found this;
pawn Код:
public OnPlayerUpdate(playerid){
SetPlayerColor(playerid, random(0xFFFFFFFF));
return true;
but that gets me this;
Код:
D:\SA-MP Server\SERVER\filterscripts\classes.pwn(104) : warning 235: public function lacks forward declaration (symbol "OnPlayerUpdate")
So could someone explain to me how to change it so that it will work?
Many thanks!
Mr. M
Re: Random Teamcolor -
Nero_3D - 04.04.2009
update your server packet
Re: Random Teamcolor -
Mr. M - 04.04.2009
Quote:
Originally Posted by ♣ ⓐⓢⓢ
update your server packet
|
Thanks for the quick reply, but how to update my server packet?
Re: Random Teamcolor -
Nero_3D - 04.04.2009
just go to
www.sa-mp.com and download the actuall server packet (should be 0.2X)
One version didnt had OnPlayerUpdate forwarded (looks like the one who you use)
Re: Random Teamcolor -
Mr. M - 04.04.2009
Quote:
Originally Posted by ♣ ⓐⓢⓢ
just go to www.sa-mp.com and download the actuall server packet (should be 0.2X)
One version didnt had OnPlayerUpdate forwarded (looks like the one who you use)
|
pawn Код:
public OnPlayerUpdate(playerid)
{
SetPlayerColor(playerid, random(0xFFFFFFFF));
return true;
}
Changed code a lil bit and downloaded the server package.
It works now, thanks for the help!