Ovale Spell Priority

Ovale Spell Priority

6M Downloads

SpellFlash Talent/Spell Replacement Issue

Nazgul084 opened this issue ยท 5 comments

commented

The previous issue I noted ( #2 ), related to the failure of SpellFlash to function when a specific Paladin spell was replaced by a spell from a talent, appears to relate to all spells that are updated and/or replaced via talents or other means (glyphs?).

In a nutshell, the original spell, not the replacement, is passed to OvaleSpellFlash. In Frame.lua, the function that changes the Ovale Action Bar icon, UpdateActionIcon, calls OvaleBestAction:GetActionInfo, which in turn calls GetActionSpellInfo, that checks for spell replacement. UpdateActionIcon, is called before OvaleSpellFlash, but the replacement spell information is never passed on to OvaleSpellFlash, and no such check occurs in the OvaleSpellFlash function.

There are multiple avenues available to solve the issue. An effective (and messy) solution is to add the following code to (around) line 225 in BestAction.lua:

            element.positionalParams[1] = spellId

This ensures that the replacement spell ID is accessible to OvaleSpellFlash when it is called. Alternatively, additional checks can also be added to OvaleSpellFlash, though it may prove preferable to conduct the replacement check even earlier, such as when the spell book is parsed or updated, and avoid the issue and CPU cycles altogether.

commented

With recent code changes that have been distributed, search for si = OvaleData.spellInfo[spellId](currently line 181) and add element.positionalParams[1] = spellId immediately below it.

commented

As a reminder, this issue still exists, and the messy fix, added right after line 225 in BestAction.lua, still works.

Furthermore, Ovale does not take advantage of the full SpellFlash API-- action bar icons are highlighted with appropriate colors, but they do not actually "flash". A fourth parameter ('1') must be passed to SpellFlashCore.FlashForm, SpellFlashCore.FlashPet, SpellFlashCore.FlashAction, and SpellFlashCore.FlashItem, in order to activate spell flashing, towards the end of the SpellFlash.lua file.

I apply these fixes after every update.

commented

The issue still exists...

commented

...and its a bug, not an enhancement request.

commented

I don't understand why Sidoine turned this from bug to enhancement... Maybe that's why the bug still exists...