CMD:lampale(playerid,params[]){{ if(IsPlayerInAnyVehicle(playerid)) { if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER) { new ora, perc, mperc; gettime(ora, perc, mperc); if(ora > 18){ new engine, lights, alarm, doors, bonnet, boot, objective; GetVehicleParamsEx(GetPlayerVehicleID(playerid), engine, lights, alarm, doors, bonnet, boot, objective); SetVehicleParamsEx(GetPlayerVehicleID(playerid), engine, false, alarm, doors, bonnet, boot, objective); } } }}return 1;}
Nem teljesen így gondoltam. Alap SA ha beér mondjuk egy sötét alagútba, akkor is felkapcsolja a lámpákat.
CMD:lampale(playerid,params[]){{ if(IsPlayerInAnyVehicle(playerid)) { if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER) { new engine, lights, alarm, doors, bonnet, boot, objective; GetVehicleParamsEx(GetPlayerVehicleID(playerid), engine, lights, alarm, doors, bonnet, boot, objective); SetVehicleParamsEx(GetPlayerVehicleID(playerid), engine, false, alarm, doors, bonnet, boot, objective); } } }return 1;}
ManualVehicleEngineAndLights();