04.08.2013, 09:07
It gives you someone please order / sethours
Have the form like this:
Have the form like this:
PHP код:
CMD:eject(playerid,params[])
{
if(AccInfo[playerid][Level] >= 3)
{
new player1, string[128], Float:x, Float:y, Float:z;
//----------------------------------------------------------------------
if(sscanf(params, "u", player1)) return
SendClientMessage(playerid, LIGHTBLUE2, "Usage: /eject [PlayerID]") &&
SendClientMessage(playerid, orange, "Function: Will Ejected from vehicle a specified player");
//----------------------------------------------------------------------
if(AccInfo[player1][Level] == ServerInfo[MaxAdminLevel] && AccInfo[playerid][Level] != ServerInfo[MaxAdminLevel]) return
SendClientMessage(playerid,red,"ERROR: You cannot use this command on this admin");
//----------------------------------------------------------------------
if(IsPlayerConnected(player1) && player1 != INVALID_PLAYER_ID)
{
if(IsPlayerInAnyVehicle(player1))
{
SendCommandToAdmins(playerid,"Eject");
if(player1 != playerid)
{
format(string,sizeof(string),"|- Administrator \"%s\" has Ejected you from your Vehicle -|", pName(playerid));
SendClientMessage(player1,blue,string);
}
format(string,sizeof(string)," |- You have ejected \"%s\" from their Vehicle -|", pName(player1));
SendClientMessage(playerid,BlueMsg,string);
GetPlayerPos(player1,x,y,z);
return SetPlayerPos(player1,x,y,z+3);
}
else return SendClientMessage(playerid,red,"ERROR: Player is not in a vehicle");
}
else return ErrorMessages(playerid, 2);
}
else return ErrorMessages(playerid, 1);
}