mirror of
https://github.com/brues-code/pfUI.git
synced 2026-09-27 18:06:02 +00:00
Performance update for nameplates: optimize update loop, combat detection and debuff rendering
- Decouple OnValueChanged from OnDataChanged to prevent expensive full updates on every HP tick - Replace UnitAffectingCombat(guid) with GetUnitField(flags) bitcheck and add 0.2s per-GUID throttle cache for GetCombatStateColor - Gate HP bar SetMinMaxValues/SetValue and text formatting behind hp/hpmax change detection - Inline castbar update into per-plate OnUpdate loop, remove dedicated castbarFrame overhead - Switch debuff slot cache from name-keyed to slot-index-keyed to fix timer reset bug when debuffs shift after expiry - Add raidGuidCache (rebuilt on RAID_ROSTER_UPDATE/PARTY_MEMBERS_CHANGED) for O(1) offtank target-name lookup - Add UNIT_FLAGS_GUID event support for instant combat flag notification (Nampower) - Extract RebuildOfftanks() to ensure offtanks table is populated at startup, not only on config change - Reuse childs table across scan ticks to reduce GC pressure - Add zoominstant config option to skip zoom animation - Add combatColorCache cleanup on plate hide and combat leave Please report any bugs that appear after this change, since it is a huge change.
This commit is contained in:
+1
-1
@@ -2935,7 +2935,7 @@ pfUI:RegisterModule("gui", "vanilla:tbc", function ()
|
||||
CreateConfig(U["nameplates"], T["Always Show On Target Units"], C.nameplates, "target", "checkbox")
|
||||
CreateConfig(U["nameplates"], T["Vertical Healthbar"], C.nameplates, "verticalhealth", "checkbox")
|
||||
|
||||
CreateConfig(nil, T["SuperWoW Settings"], nil, nil, "header")
|
||||
CreateConfig(nil, T["Nampower Settings"], nil, nil, "header")
|
||||
CreateConfig(U["nameplates"], T["Overwrite Border Color With Combat State"], C.nameplates, "outcombatstate", "checkbox")
|
||||
CreateConfig(U["nameplates"], T["Overwrite Health Color With Combat State"], C.nameplates, "barcombatstate", "checkbox")
|
||||
CreateConfig(U["nameplates"], T["Overwrite If Unit Is Attacking You"], C.nameplates, "ccombatthreat", "checkbox")
|
||||
|
||||
+526
-747
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user