Pulse stop
ennvina opened this issue · 1 comments
SAOs may stop pulsing when an aura overwrites another aura with the same spell identifier.
For example, with Fingers of Frost:
- initially it grants grants 2 charges
- they are displayed on the left side and the right side
- both are pulsing at the same time
- when a charge is lost:
- the right side is hidden, which is intended
- the left side is still displayed, which is intended
- the left side stops pulsing, which is NOT intended
This is probably due to the face that there is no continuum between stacking auras.
For example, if an aura has goes from 1 stack to 2 stacks, currently:
- the aura with stack == 1 is hidden
- and then aura with stack == 2 is displayed
Because they share the same spell identifier, animations will conflict with each other.
The quick'n'dirty way to solve this would be to use fake, diffferent "internal" spell IDs:
- this would probably work, to some extent
- it means the "internal fake id" must be implemented, which is ugly and confusing
- it will also create weird transitions with show/hide transitions blending altogether
The nicer solution would be to rework how stackable auras are handled:
- currently, each number of stacks is treated as a different activation trigger
- instead, it should be possible to detect that stacks are "going from 1 to 2"
- basically, it would replace
hide(1); show(2);
bytransition(1,2);
Please look at SAO.SPELL_AURA
in common.lua
which already detects when stacks change:
-- Deactivate old aura and activate the new one
self:DeactivateOverlay(spellID);
self:ActivateOverlay(count, select(3,unpack(auras[count])));
While is is tempting to simply add a king of ChangeOverlayCount
method, it’s not that easy:
- stackable auras may have different display options (different scale, texture, location, etc.)
- for example, Fingers of Frost with stacks == 1 is "Left" and stacks == 2 is "Left + Right"
- because of that, extra caution is required to correctly handle these transitions
Fixed in #33