ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   General Authoring Discussion (https://www.esoui.com/forums/forumdisplay.php?f=174)
-   -   EVENT_EFFECT_CHANGED Problem (https://www.esoui.com/forums/showthread.php?t=5238)

circonian 10/29/15 02:07 PM

EVENT_EFFECT_CHANGED Problem
 
The event EVENT_EFFECT_CHANGED is firing an EFFECT_RESULT_GAINED for buffs that the character already has when weapons are swapped.

If the character already has the buff it should either fire EFFECT_RESULT_FADED first, before firing EFFECT_RESULT_GAINED to regain the buff, or don't fire the EFFECT_RESULT_GAINED at all. Or possibly an EFFECT_RESULT_UPDATED would also be logical.

haggen 11/21/15 06:20 PM

Meanwhile you could set a flag on EVENT_ACTIVE_WEAPON_PAIR_CHANGED and then avoid the visual update on the buffs (that is, only if it occurs BEFORE the EVENT_EFFECT_CHANGED).

circonian 11/21/15 08:29 PM

Quote:

Originally Posted by haggen (Post 24342)
Meanwhile you could set a flag on EVENT_ACTIVE_WEAPON_PAIR_CHANGED and then avoid the visual update on the buffs (that is, only if it occurs BEFORE the EVENT_EFFECT_CHANGED).

Thanks for the info. I'm not using the weapon pair change event, but using a flag is sort of what I'm doing. If it passes in an effect with EFFECT_RESULT_GAINED and the addon already has that effect registered then the addon just treats it as an EFFECT_RESULT_UPDATED.


All times are GMT -6. The time now is 11:22 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI