Which function type should i choose? - 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: Which function type should i choose? (
/showthread.php?tid=456497)
Which function type should i choose? -
Micius - 06.08.2013
Which function type should i choose?
For example i want to make teleport player function:
TeleportPlayerToMyPoint(playerid)
Should i choose a stock, forward, or simple private function(or other)?
Re: Which function type should i choose? -
Vince - 06.08.2013
Neither. Plain. No keywords. A custom function should only be public if it's on a timer. It should only be stock if it's in an include.
Re: Which function type should i choose? -
Vanter - 06.08.2013
pawn Код:
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
SetPlayerPos(ID,x+1,y,z);
SetPlayerVirtualWorld(ID,GetPlayerVirtualWorld(playerid));
SetPlayerInterior(ID,GetPlayerInterior(playerid));
you don't need to make a stock or anything for that really