Way to detect damaged entities?
Posted: Mon Jul 04, 2016 1:00 am
It there anyway to detect when any entity is damaged?
The in-game audio alerts for when your stuff getting damaged is incredibly delayed. I often find myself with a chunk of my factory destroyed before the game decides to even play the alert-damaged sound effect let alone when something gets destroyed. If I'm watching for it the alert icons they appear but the sound effect doesn't always play or plays right as the icon disappears.
I've written a "personal" mod the tells me every time one for my units/structures dies. Now I'd like to know when one of my structured gets under 60% health.
Only way I can think of or find is by abusing on_tick to scan all entities hp values and trigger the alert as needed.
The in-game audio alerts for when your stuff getting damaged is incredibly delayed. I often find myself with a chunk of my factory destroyed before the game decides to even play the alert-damaged sound effect let alone when something gets destroyed. If I'm watching for it the alert icons they appear but the sound effect doesn't always play or plays right as the icon disappears.
I've written a "personal" mod the tells me every time one for my units/structures dies. Now I'd like to know when one of my structured gets under 60% health.
Only way I can think of or find is by abusing on_tick to scan all entities hp values and trigger the alert as needed.