Hi!
I want to ask if there is a way to create event listener that e.g. fires an event if some entity’s enabled is chnaged from true to false and vice versa.
Oddly enough, we don’t
Please do make feature request for this on the engine github repository as that would be pretty useful
You could monitor the state event as a workaround. Check out this thread as an example:
1 Like
That works if you are coding in a script instance attached to that entity.
But still it can be quite useful to have this per entity without that requirement. I imagine since the ‘destroy’ even is there, an entity state event makes sense.
For now I have if statement (where I control the state of entity.enabled) in update function as a workaround and it works