15.05.2013, 23:56
(
Последний раз редактировалось [..MonTaNa..]; 18.01.2014 в 20:52.
)
Removed.
CMD:gotoobject(playerid, params[])
{
if(!IsCnRAdmin(playerid)) return UnknownCMD(playerid);
new objectid;
if(sscanf(params, "d", objectid)) return SendClientMessage(playerid, COLOR_RED, "USAGE: /gotoobject (Object Editing ID)");
if(Dead[playerid] == 1) return SendClientMessage(playerid, COLOR_RED, "You Cannot Use This Command When Dead.");
if(IsSpecing[playerid] == 1) return SendClientMessage(playerid, COLOR_RED, "You Cannot Use This Command When Spectating.");
if(PlayerObjectCount[playerid] == 0) return SendClientMessage(playerid, COLOR_RED, "You Have No Objects To Go To. Use /addobject");
if(objectid > PlayerObjectCount[playerid]) return SendClientMessage(playerid, COLOR_RED, "Invalid Object Editing ID");
new Float:xo, Float:yo, Float:zo;
GetObjectPos(PlayerObject[playerid][objectid], xo, yo, zo);
SetPlayerPos(playerid, xo+1, yo+1, zo+1);
AdminCMD(playerid, "GOTOOBJECT");
return 1;
}