17.11.2011, 21:24
i have problem with /goto
i can port with car, pls help.. how to port with a car to person?
pawn Код:
CMD:goto(playerid, params[])
{
new id, car;
if(sscanf(params, "u", id))return Use(playerid, "/goto [name/ID]");
else if(PlayerInfo[playerid][pAdmin] < 1)return SendAdmin(playerid, "Not admin!");
new Float:x, Float:y, Float:z;
GetPlayerPos(id, x, y, z);
SetPlayerPos(playerid, x+1, y, z);
if(IsPlayerInVehicle(playerid, car))
{
SetVehiclePos(car, x, y, z);
PutPlayerInVehicle(playerid, car, 0);
}
SendClientMessage(playerid, Grey, "Teleport.");
return 1;
}