Hack a traffic light by using the “third-eye” mechanic. Hacking the light turns it green for X amount of time. Upon completing the hack, the traffic light cycles through the different lights once as a display of success.
A known issue is that peds don’t react to the change of light.
I don’t know a way around this issue unless you’d change the driving style of nearby peds.
Very simple resource, far from perfect. Hopefully, it can help someone with something.
Feel free to edit the code and change it to your liking.
Don’t redistribute this resource claiming it to be yours.
Hello, nice release !
I think there might be an issue with server sync, when the event pl-traffichack:changeLights is triggered, other players can’t know which object is the traffic light because it is not passed with it.
Hmm it’s a bit harder than I thought because default traffic lights seems to be considered as local object and not network object, so ObjToNet do not get its id.