mirror of
https://github.com/brues-code/SuperCleveRoidMacros.git
synced 2026-09-16 03:38:00 +00:00
use pfui swingtimer if SP not available, fix vanish regeant count
This commit is contained in:
@@ -58,7 +58,7 @@ function CleveRoids.IndexSpells()
|
||||
else
|
||||
local cost, reagent = CleveRoids.GetSpellCost(i, bookType)
|
||||
-- Fallback for known reagent spells if tooltip scan failed
|
||||
if not reagent and CleveRoids.ReagentBySpell then
|
||||
if (not reagent or reagent == "") and CleveRoids.ReagentBySpell then
|
||||
reagent = CleveRoids.ReagentBySpell[spellName]
|
||||
end
|
||||
local texture = GetSpellTexture(i, bookType)
|
||||
@@ -84,6 +84,10 @@ function CleveRoids.IndexSpells()
|
||||
}
|
||||
spells[bookType][spellName].highest = spells[bookType][spellName][spellRank]
|
||||
end
|
||||
-- For spells with no rank string, the base entry is the highest
|
||||
if not spellRank and not spells[bookType][spellName].highest then
|
||||
spells[bookType][spellName].highest = spells[bookType][spellName]
|
||||
end
|
||||
|
||||
if reagent then
|
||||
CleveRoids.countedItemTypes[reagent] = true
|
||||
@@ -458,7 +462,12 @@ function CleveRoids.GetSpell(text)
|
||||
|
||||
for book, spells in CleveRoids.Spells do
|
||||
if spells and spells[name] then
|
||||
return spells[name][rank or "highest"]
|
||||
local entry = spells[name][rank or "highest"]
|
||||
if entry then return entry end
|
||||
-- Fallback: for spells with no rank, return base entry
|
||||
if not rank and spells[name].spellSlot then
|
||||
return spells[name]
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user