mirror of
https://github.com/brues-code/SuperCleveRoidMacros.git
synced 2026-09-16 03:38:00 +00:00
Replace GetSpellRecField name/rank reads with C_Spell equivalents
Swap 166 call sites from GetSpellRecField(id, "name") to C_Spell.GetSpellName(id) and GetSpellRecField(id, "rank") to C_Spell.GetSpellSubtext(id) across Core, Conditionals, Utility, ComboPointTracker, CursiveCustomSpells, pfUI, OverflowBuffFrame, and Generic. Guard forms and the _GetSpellRecField alias calls collapse to the direct C_Spell call. GetSpellRecField stays for fields with no C_Spell equivalent (school, spellIconID, mechanic, effectMechanic, effectApplyAuraName, stackAmount, rangeIndex) and inside the NampowerAPI wrapper layer.
This commit is contained in:
@@ -378,9 +378,9 @@ function CleveRoids.GetActionButtonInfo(slot)
|
||||
if not actionType then return end
|
||||
|
||||
if actionType == "spell" and id then
|
||||
local rank = GetSpellRecField(id, "rank")
|
||||
local rank = C_Spell.GetSpellSubtext(id)
|
||||
if rank == "" then rank = nil end
|
||||
return "SPELL", id, GetSpellRecField(id, "name"), rank
|
||||
return "SPELL", id, C_Spell.GetSpellName(id), rank
|
||||
elseif actionType == "item" and id then
|
||||
local item = CleveRoids.GetItem(id)
|
||||
return "ITEM", id, (item and item.name)
|
||||
|
||||
Reference in New Issue
Block a user