08.04.2012, 08:52
Hi guys,
do someone can fix this code? This is a /get command, and this code works only for ID 0.
do someone can fix this code? This is a /get command, and this code works only for ID 0.
Код:
CMD:get(playerid, params[]){ if(Donator[playerid]) { new tmp[256]; tmp = ""; if(!IsPlayerConnected(strval(tmp))) { SendClientMessage(playerid, RAUDONA,"This player dosn't exists."); } else { new Float:X; new Float:Y; new Float:Z; new Float:Angle; if(IsPlayerInAnyVehicle(strval(tmp))) { new VehicleID; VehicleID = GetPlayerVehicleID(strval(tmp)); GetPlayerPos(playerid,X,Y,Z); SetVehiclePos(VehicleID, X + 0.01, Y + 0.01, Z); GetPlayerFacingAngle(playerid,Angle); SetPlayerFacingAngle(strval(tmp),Angle); } else { GetPlayerPos(playerid,X,Y,Z); GetPlayerFacingAngle(playerid,Angle); SetPlayerFacingAngle(strval(tmp),Angle); SetPlayerPos(strval(tmp), X + 0.01, Y + 0.01, Z); } SendClientMessage(playerid, BALTA,"Player has been teleported to you."); } } else { SendClientMessage(playerid, MELYNA, "This command can use only administrator."); } return 1; }