05.08.2011, 02:38
How can I get this command:
So that when the person turns on the engine, they can't turn the engine on again?, because people in my server are spamming the command /eon and it get's really annoying, like is there a way to add:
SendClientMessage(playerid, GREY, "The vehicles engine is already turned on.");
If so, please can someone help?, Thanks.
pawn Код:
command(eon, playerid, params[])
{
#pragma unused params
if(GetPlayerState(playerid) == 2)
{
{
new string[128], engine, lights, alarm, doors, bonnet, boot, veh, objective;
format(string, sizeof(string), "%s has turned their engine on.", RemoveUnderScore(playerid));
NearByMessage(playerid, PINK, string);
veh = GetPlayerVehicleID(playerid);
GetVehicleParamsEx(veh, engine, lights, alarm, doors, bonnet, boot, objective);
SetVehicleParamsEx(veh, 1, lights, alarm, doors, bonnet, boot, 0);
}
}
else
{
SendClientMessage(playerid, WHITE, "You are not driving a vehicle!");
}
return 1;
}
SendClientMessage(playerid, GREY, "The vehicles engine is already turned on.");
If so, please can someone help?, Thanks.