Originally Posted by decay2
If it is intended to stay it would be really helpful if there was an indication who caused a particular effect in EVENT_EFFECT_CHANGED. It would be enough to know if the player caused it or not. (It is done like this in GetUnitBuffInfo(...) however this one requires a unittag which is not always available)
|
unitTag == "player" or better yet:
self.control:AddFilterForEvent(EVENT_EFFECT_CHANGED, REGISTER_FILTER_UNIT_TAG, "player")
EVENT_MANAGER:AddFilterForEvent("Name", EVENT_EFFECT_CHANGED, REGISTER_FILTER_UNIT_TAG, "player")