In earlier versions of the game the light manager was able to set the state of a light by the given ELightType and side. So via user action, they could for example only enable rear lights for covert convoys.
Currently in 0.9.7.106 the following line does NOTHING
BaseLightManagerComponent lightManager = BaseLightManagerComponent.Cast(worldEntityComponent); lightManager.SetLightsState(ELightType.Head, true);
The only way to enable the headlights is by using
lightManager.SetLightsState(ELightType.Presence, true);
and relying on the IsPresenceLight bool on the Head light slot to associate it with that.
I understand that these presets might be easier to deal with than to say for presence manually enable both Head and Rear but I would still like to have the option to do that if I want to.
I hope it is only a bug. If not please reconsider the decision. I have provided you with a valid use-case. It throws moddabilty out the window if individual lights can not be controlled.
Oh and while we are at it, why do vehicles like {F649585ABB3706C4}Prefabs/Vehicles/Wheeled/M151A2/M151A2.et not have the side value yet? There are two Head and two Rear slots but all have -1 as the side. I guess that is because the .conf preset was used for them? But then I think the sides should manually be assigned. Because again, right now you can't just say "Enable Head on right side" via scrip. You need to guess which one of the two head slots might be the right one.
UPDATE on 0.9.8.50
Now enabling head and rear manually does something - the lights are there - but the lamp materials are not changed. Correctly