AddPlayerClass - 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)
+--- Thread: AddPlayerClass (
/showthread.php?tid=488145)
AddPlayerClass -
MatriXgaMer - 16.01.2014
Hey guys need help i was trying to do if an player select skin 102 (Ballas one) that it display gametext "Ballas" but it dont work on Game mode init;
pawn Код:
AddPlayerClass(102, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0) || GameTextForPlayer(MAX_PLAYERS, "BALLAS", 3000, 3);
but it gives no errors but it not displays it on skin selection.
Re: AddPlayerClass -
IPrototypeI - 17.01.2014
Quote:
Originally Posted by MatriXgaMer
Hey guys need help i was trying to do if an player select skin 102 (Ballas one) that it display gametext "Ballas" but it dont work on Game mode init;
pawn Код:
AddPlayerClass(102, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0) || GameTextForPlayer(MAX_PLAYERS, "BALLAS", 3000, 3);
but it gives no errors but it not displays it on skin selection.
|
You initalize the skins with AddPlayerClass or AddPlayerClassEx for the ClassSelection under OnGameModeInit.
But if you want to display this message when he choose the skin then you have to use the callback.
pawn Код:
public OnPlayerRequestClass(playerid,classid)
this callback is called when you change the class(skin) in the classselection.
https://sampwiki.blast.hk/wiki/OnPlayerRequestClass