Idea suggestion
Would it be possible please to add an option to filter on force in "LuaEntityDamagedEventFilter" ?Reason
In our scenario we can sometimes result in having a lot of attacks at same time by lot of biters at different location to big defenses (a long line of flamers with like 3 row or more of lasers), resulting in a lot "on_entity_damaged" being fired, which is bad performance wise.We got 2 forces for biters, one that needs to trigger on_entity_damaged (but very small amount of biters), one that doesn't (a lot and a lot more of biters compared to the other force).
I think it would be better performance wise if this event "on_entity_damaged" is not even triggered if it's not the force we wanted in the code by using "LuaEntityDamagedEventFilter" with a new force filter option.
Sure we have a check at the beginning on "entity_damaged" but it doesn't prevent the event being triggered for nothing (there is no need for event to be triggered when it's the wrong force).
Thanks in advance,
Regards,
Masamune00