02.11.2011, 13:58
hey guys what is the problem in this admin command because i got 9 warnings :P actually how i will make a vehicle front of the player who asked it btw here is the command and tell me what is wrong D:
pawn Код:
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "ERROR:Only Admins can use this command for cars /carmenu!");
if(strcmp(cmd,"/nrg", true) ==0){
if(IsPlayerInAnyVehicle(playerid))
SendClientMessage(playerid, COLOR_RED, "ERROR:You are already in a vehicle..!");
else
{
new vehicleid= GetPlayerVehicleID(playerid);
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid, x, y, z);
CreateVehicle(522, x,y,z,0,0);
SetVehiclePos(vehicleid, GetPlayerPos(playerid));
PutPlayerInVehicle(playerid, 522,0);
SendClientMessage(playerid, COLOR_YELLOW, "Your Personal Nrg has been created!");
GameTextForPlayer(playerid, "~w~personal ~b~n~g~r~p~g ~w~ is ~y~created~w~!!!",3000,5);
}