10.03.2013, 01:36
pawn Код:
LEANCMD:(seats)
{
SCM(playerid, COLOR_AO, "Carseats ID");
SCM(playerid, COLOR_AO, "0 - Driver");
SCM(playerid, COLOR_AO, "1 - Front Passenger");
SCM(playerid, COLOR_AO, "2 - Back left passenger");
SCM(playerid, COLOR_AO, "3 - Back right passenger");
return 1;
}
LEANCMD:(getin)
{
new currentveh, id, seat;
currentveh = GetPlayerVehicleID(playerid);
if(!IsPlayerInAnyVehicle(playerid)) return SCM(playerid, COLOR_GREY, "You have to be inside a vehicle to teleport a player inside your car");
if(PlayerInfo[playerid][pAdmin] < 1) return SCM(playerid, COLOR_GREY,"You are not authorized to use this command");
if(sscanf(params, "ui", id, seat)) return SCM(playerid, COLOR_GREY, "/getin [partofname/playerid] [seat] [/seats to check seatIDs]");
if(!IsPlayerConnected(id)) return SCM(playerid, COLOR_GREY, "This player is not connected");
if(IsPlayerInVehicle(id, currentveh))
{
RemovePlayerFromVehicle(id);
PutPlayerInVehicle(id, currentveh, seat);
}
else
{
PutPlayerInVehicle(id, currentveh, seat);
}
return 1;
}
LEANCMD:(goin)
{
new currentveh, id, seat;
if(PlayerInfo[playerid][pAdmin] < 1) return SCM(playerid, COLOR_GREY,"You are not authorized to use this command");
if(sscanf(params, "ui",id, seat)) return SCM(playerid, COLOR_GREY, "/goin [partofname/playerid] [seat] [/seats to check seatIDs]");
if(!IsPlayerConnected(id)) return SCM(playerid, COLOR_GREY, "This player is not connected");
else
{
currentveh = GetPlayerVehicleID(id);
PutPlayerInVehicle(playerid, currentveh, seat);
}
return 1;
}
here u go