13.12.2016, 16:28
got it work thx, iLearner
please delete thread
please delete thread
GetPlayerName(playerid, playername, sizeof(playername));
CMD:engine(playerid, params[])
{
new carid = GetPlayerVehicleID(playerid);
new string[100], pname[24];
GetPlayerName(playerid, pname, sizeof(pname));
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
if(Fuel[carid] == 0.0) return SCM(playerid, COLOR_RED, "** Tqveni Manqanis Avzi Carielia.");
switch(EngineState[carid])
{
case false:
{
EngineState[carid] = true;
GetVehicleParamsEx(carid, engine, lights, alarm, doors, bonnet, boot, objective);
SetVehicleParamsEx(carid, true, lights, alarm, doors, bonnet, boot, objective);
format(string, sizeof(string), "%s-m(a) Gadaatriala Gasagebi Da Daqoqa Manqana.", pname);
SetPlayerChatBubble(playerid, string, COLOR_PURPLE, 20.0, 5*1000);
ProxDetector(20.0, playerid, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
}
case true:
{
EngineState[carid] = false;
GetVehicleParamsEx(carid, engine, lights, alarm, doors, bonnet, boot, objective);
SetVehicleParamsEx(carid, false, lights, alarm, doors, bonnet, boot, objective);
format(string, sizeof(string), "%s-m(a) Gadaatriala Gasagebi Da Chaaqro Manqana.", pname);
SetPlayerChatBubble(playerid, string, COLOR_PURPLE, 20.0, 5*1000);
ProxDetector(20.0, playerid, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
}
}
}
return 1;
}