How to make the light of vehicles work on daytime?
#1

As the title says?
Reply
#2

https://sampwiki.blast.hk/wiki/ManualVehicleEngineAndLights
Reply
#3

Thanks!
Reply
#4

That nay not working as what I want.
In my server, when I /engine cars, the lights will be turned on automatic, but shines at nights only. I want to get it changed to the lights can be turned on and works on daytime..
Reply
#5

Quote:

Use this function before any player connects (OnGameModeInit) to tell all clients that the script will toggle the light and engine status by itself so that the vehicle doesn't start the engine when you enter it.

That function won't turn the lights on for you when you enter the vehicle. You need to code it like that.

By using this functions, lights are working to both day and night.

So, when you execute /engine command for the vehicle etc (don't forget to get the vehicleid, it is just an example)
pawn Код:
new engine, lights, alarm, doors, bonnet, boot, objective;
GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);
SetVehicleParamsEx(vehicleid, 1, 1, alarm, doors, bonnet, boot, objective);
// Turning the engine and lights on!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)