24.01.2013, 14:48
See i need some help with this script here :
I want to add something like :
But i don't have the idea where i have to put them . Any help please ?
pawn Код:
new engine, lights, alarm, doors, bonnet, boot, objective, vehicleid;
vehicleid = GetPlayerVehicleID(playerid);
if (AVehicleData[vehicleid][Fuel] > 0)
{
if ((newkeys & KEY_SUBMISSION) && !(oldkeys & KEY_SUBMISSION) && IsPlayerInAnyVehicle(playerid) && GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);
SetVehicleParamsEx(vehicleid, 1, 1, alarm, doors, bonnet, boot, objective);
SendClientMessage(playerid, COLOR_PINK, "Engine turned on !");
}
}
pawn Код:
else // when the GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective); engine and lights are on
SetVehicleParamsEx(vehicleid, 0, 0, alarm, doors, bonnet, boot, objective);
SendClientMessage(playerid, COLOR_PINK, "Engine turned off!");