[Fix] ShadowedUnitFrames — Aura display crash on Classic Anniversary (2.5.6 / build 68575) - #72
Open
lovemoon0314 wants to merge 13 commits into
Open
[Fix] ShadowedUnitFrames — Aura display crash on Classic Anniversary (2.5.6 / build 68575)#72lovemoon0314 wants to merge 13 commits into
lovemoon0314 wants to merge 13 commits into
Conversation
The 2.5.6 client removed the global UnitAura function and the global DebuffTypeColor table, which the auras/highlight/health modules rely on. - Wrap aura lookups in a SUF_UnitAura helper that falls back to C_UnitAuras.GetAuraDataByIndex + AuraUtil.UnpackAuraData when the global UnitAura is unavailable (return order is identical). - Rebuild the global DebuffTypeColor table from the engine's DEBUFF_TYPE_*_COLOR constants, with fixed RGB fallbacks. Guarded so it is a no-op on clients where these globals still exist.
|
Just signed in to thank you so so much! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Since the 2.5.6 patch, ShadowedUnitFrames throws Lua errors and buffs/debuffs stop displaying correctly. This is because Blizzard removed the global UnitAura function and the global DebuffTypeColor table in 2.5.6, both of which SUF relies on.
I've patched the addon to restore full functionality on 2.5.6. The fix:
Replaces the removed UnitAura with a compatibility wrapper built on C_UnitAuras.GetAuraDataByIndex + AuraUtil.UnpackAuraData (which returns values in the exact same order as the old UnitAura, so no downstream changes are needed). The wrapper falls back to the native UnitAura on older clients, so it stays compatible with Era/Wrath.
Rebuilds the removed DebuffTypeColor table from the engine's DEBUFF_TYPE_*_COLOR constants, with fixed-RGB fallbacks.
All aura code paths are covered — standard buff/debuff frames, UnitAuraBySpell (druid shapeshift bar etc.), and the optional aura-indicators feature.
Tested on 2.5.6 (build 68575), on a Priest:
No Lua errors on login or when targeting units with active buffs/debuffs.
Buffs and debuffs display correctly on player/target/party frames, with the proper debuff-type border colors (Magic/Curse/Disease/Poison).
Debuff highlight and tooltips work as expected.
I've only been able to test on a Priest so far — the fix is class-agnostic (it only touches the aura lookup layer), but if you play another class, testing and feedback would be much appreciated, especially for the druid shapeshift bar and the optional aura-indicators feature.
Download (Classic branch): https://github.com/lovemoon0314/ShadowedUnitFrames/tree/classic Click Code → Download ZIP, then extract into your Interface/AddOns folder, overwriting the existing SUF files.
A pull request has also been opened against the upstream repo, so once it's merged the official version will include the fix. Feedback and testing welcome!