SA-MP Forums Archive
ZCMD GetHere - 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: ZCMD GetHere (/showthread.php?tid=272015)



ZCMD GetHere - Shockey HD - 26.07.2011

Im on a role with my admin script but, i need a ZCMD gethere command. Can anyone supply me with one?


Re: ZCMD GetHere - Kitten - 26.07.2011

pawn Код:
//You Must have sscanf - easiest way to do it.
CMD:gethere(playerid,params[])
{
    new targetid, Float:x, Float:y, Float:z;
    if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, COLOR, "USAGE: /gethere [id]");
    if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, COLOR, "That player is not connected");
    GetPlayerPos(playerid, x, y, z);
    SetPlayerPos(targetid, x, y+0.5, z+0.5);
    return 1;
}



Re: ZCMD GetHere - Shockey HD - 26.07.2011

Quote:
Originally Posted by Kitten
Посмотреть сообщение
pawn Код:
//You Must have sscanf - easiest way to do it.
CMD:gethere(playerid,params[])
{
    new targetid, Float:x, Float:y, Float:z;
    if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, COLOR_ORANGE, "USAGE: /gethere [id]");
    if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, COLOR_WHITE, "That player is not connected");
    GetPlayerPos(playerid, x, y, z);
    SetPlayerPos(targetid, x, y+0.5, z+0.5);
    return 1;
}
Thanks Kitten :]