Real Halogen vehicle lights
-
Hey
maybe some of you have noticed how all vehicle lights turn on and off as if they were LED lights in gta v.
I wanted to make a mod to gradually show the emissive for the brakelights for example. Check this vid with timestamp if you don't understand what I'm talking about:
Go to second timestamp 0:26
You can clearly see those brakelights have a halogen effect, they don't just turn on in one frame as if they were led, as it happens in gta v.
Since emissives in vehicles are just a mesh that shows and hides, I've been thinking of finding the function that draws them ? and maybe hook it and use a loop to gradually increase alpha value ? same for coronas, but I don't know if this logic will work because I can't find the function(s) that draw those things.Maybe someone with more experience in reversing has any ideas regarding this, I'd appreciate if you post them below.
-
@insus100 Good topic!
-
I have seen some headlights having this effect. Their intensity gradually increases instead of just turning on, though when you turn off they instantly turn off.
I'm not entirely sure but this might be related to popup headlights. I don't have much hope but I will try to replicate this effect using carcols and can have a look into the car's headlights after exporting it's yft to xml with codewalker.
-
@Aurora11 said in Real Halogen vehicle lights:
I have seen some headlights having this effect. Their intensity gradually increases instead of just turning on, though when you turn off they instantly turn off.
I'm not entirely sure but this might be related to popup headlights. I don't have much hope but I will try to replicate this effect using carcols and can have a look into the car's headlights after exporting it's yft to xml with codewalker.
It's true that for popup headlights corona looks like it increases in size while it's popping up (I think it's just because it's moving and it's setup to change size by angle), but the mesh shows in one frame just like all other lights. I'm afraid that for something like this we will need to reverse game functions and see.
There's a native that draws vehicle brakelights on for one frame: https://alloc8or.re/gta5/nativedb/?n=0x92B35082E0B42F66
I've tried this native and if it's called on every frame, it will force brakelights on. The idea is looking what's this native doing and what functions it calls to draw the emmissives. I'll try dumping gta v memory and see but I'm really amateur on reversing games.