Posts: 30
Threads: 5
Joined: Jun 2013
Reputation:
0
That didnt work. Is it for a admin system or rcon admin? As Iam using rcon.
I got sscanf2
Posts: 2,593
Threads: 34
Joined: Dec 2007
pawn Код:
CMD:eject(playerid, params[])
{
new ID;
if(!IsPlayerAdmin(playerid)) SendClientMessage(playerid,RED,"[AG] You do not have enough Admin Permissions to execute this Command!");
else if(isnull(params)) SendClientMessage(playerid,-1,"Usage: /eject [playerid]");
else if(!IsPlayerConnected((ID = strval(params)))) SendClientMessage(playerid,RED,"Player is not online");
else{
new veh = GetPlayerVehicleID(ID);
if(veh == 0 || veh == INVALID_VEHICLE_ID) SendClientMessage(playerid,RED,"Player is not in vehicle");
else{
RemovePlayerFromVehicle(ID);
SendClientMessage(playerid, -1, "Player got Ejected!");
}
}
return 1;
}