Skip to content

Commit

Permalink
TWW Updates #8
Browse files Browse the repository at this point in the history
  • Loading branch information
Kkthnx committed Aug 17, 2024
1 parent 0264c3f commit 7608800
Show file tree
Hide file tree
Showing 13 changed files with 156 additions and 170 deletions.
1 change: 1 addition & 0 deletions KkthnxUI/Modules/ActionBars/ButtonStyle.lua
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ function Module:StyleActionButton(button)
end
if autoCastable then
autoCastable:SetTexCoord(0.217, 0.765, 0.217, 0.765)
autoCastable:SetDrawLayer("OVERLAY", 3)
autoCastable:SetAllPoints()
end
if icon then
Expand Down
4 changes: 2 additions & 2 deletions KkthnxUI/Modules/Auras/Lumos/DemonHunter.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ end

local function UpdateSpellStatus(button, spellID)
button.Icon:SetTexture(GetSpellTexture(spellID))
if IsUsableSpell(spellID) then
if C_Spell.IsSpellUsable(spellID) then
button.Icon:SetDesaturated(false)
else
button.Icon:SetDesaturated(true)
Expand All @@ -38,7 +38,7 @@ function Module:ChantLumos(self)
do
local button, spellID = self.lumos[1], 228477
UpdateSpellStatus(button, spellID)
button.Count:SetText(GetSpellCount(spellID))
button.Count:SetText(_Spell.GetSpellCastCount(spellID))
end

UpdateBuff(self.lumos[2], 258920, 258920, true)
Expand Down
6 changes: 3 additions & 3 deletions KkthnxUI/Modules/Auras/Lumos/Druid.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ end

local function UpdateSpellStatus(button, spellID)
button.Icon:SetTexture(GetSpellTexture(spellID))
if IsUsableSpell(spellID) then
if C_Spell.IsSpellUsable(spellID) then
button.Icon:SetDesaturated(false)
else
button.Icon:SetDesaturated(true)
Expand All @@ -32,14 +32,14 @@ function Module:ChantLumos(self)
local currentPower = UnitPower("player", 8)
do
local button = self.lumos[1]
local count = GetSpellCount(190984)
local count = C_Spell.GetSpellCastCount(190984)
UpdateBuff(button, 190984, 48517)
button.Count:SetText(count > 0 and count or "")
end

do
local button = self.lumos[2]
local count = GetSpellCount(194153)
local count = C_Spell.GetSpellCastCount(194153)
UpdateBuff(button, 194153, 48518)
button.Count:SetText(count > 0 and count or "")
end
Expand Down
2 changes: 1 addition & 1 deletion KkthnxUI/Modules/Auras/Lumos/Evoker.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ end

local function UpdateSpellStatus(button, spellID)
button.Icon:SetTexture(GetSpellTexture(spellID))
if IsUsableSpell(spellID) then
if C_Spell.IsSpellUsable(spellID) then
button.Icon:SetDesaturated(false)
else
button.Icon:SetDesaturated(true)
Expand Down
2 changes: 1 addition & 1 deletion KkthnxUI/Modules/Auras/Lumos/Hunter.lua
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ end

local function UpdateSpellStatus(button, spellID)
button.Icon:SetTexture(GetSpellTexture(spellID))
if IsUsableSpell(spellID) then
if C_Spell.IsSpellUsable(spellID) then
button.Icon:SetDesaturated(false)
else
button.Icon:SetDesaturated(true)
Expand Down
6 changes: 3 additions & 3 deletions KkthnxUI/Modules/Auras/Lumos/Monk.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ end

local function UpdateSpellStatus(button, spellID)
button.Icon:SetTexture(GetSpellTexture(spellID))
if IsUsableSpell(spellID) then
if C_Spell.IsSpellUsable(spellID) then
button.Icon:SetDesaturated(false)
else
button.Icon:SetDesaturated(true)
Expand All @@ -31,7 +31,7 @@ function Module:ChantLumos(self)
if spec == 1 then
UpdateCooldown(self.lumos[1], 121253, true)
UpdateCooldown(self.lumos[2], 322101, true)
self.lumos[2].Count:SetText(GetSpellCount(322101))
self.lumos[2].Count:SetText(C_Spell.GetSpellCastCount(322101))
UpdateBuff(self.lumos[3], 215479, 215479)
UpdateBuff(self.lumos[4], 325092, 325092, nil, "END")
UpdateBuff(self.lumos[5], 322507, 322507, true)
Expand All @@ -47,7 +47,7 @@ function Module:ChantLumos(self)

do
local button = self.lumos[3]
button.Count:SetText(GetSpellCount(101546))
button.Count:SetText(C_Spell.GetSpellCastCount(101546))
UpdateSpellStatus(button, 101546)
end

Expand Down
15 changes: 1 addition & 14 deletions KkthnxUI/Modules/Auras/Lumos/Paladin.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ if K.Class ~= "PALADIN" then
return
end

local IsUsableSpell, IsPlayerSpell = IsUsableSpell, IsPlayerSpell
local C_Spell_IsSpellUsable, IsPlayerSpell = C_Spell.IsSpellUsable, IsPlayerSpell
local GetCurrentGlyphNameForSpell = GetCurrentGlyphNameForSpell

local function UpdateCooldown(button, spellID, texture)
Expand All @@ -16,19 +16,6 @@ local function UpdateBuff(button, spellID, auraID, cooldown, glow)
return Module:UpdateAura(button, "player", auraID, "HELPFUL", spellID, cooldown, glow)
end

local function UpdateDebuff(button, spellID, auraID, cooldown, glow)
return Module:UpdateAura(button, "target", auraID, "HARMFUL", spellID, cooldown, glow)
end

local function UpdateSpellStatus(button, spellID)
button.Icon:SetTexture(GetSpellTexture(spellID))
if IsUsableSpell(spellID) then
button.Icon:SetDesaturated(false)
else
button.Icon:SetDesaturated(true)
end
end

local function checkQueenGlyph()
local name, spellID = GetCurrentGlyphNameForSpell(86659)
Module.hasQueenGlyph = name and spellID == 212642
Expand Down
2 changes: 1 addition & 1 deletion KkthnxUI/Modules/Auras/Lumos/Shaman.lua
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ function Module:ChantLumos(self)
elseif IsPlayerSpell(117014) then
UpdateCooldown(button, 117014, true)
else
if IsUsableSpell(8042) then
if C_Spell.IsSpellUsable(8042) then
button.Icon:SetDesaturated(false)
K.ShowOverlayGlow(button.glowFrame)
else
Expand Down
2 changes: 1 addition & 1 deletion KkthnxUI/Modules/Auras/Lumos/Warrior.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ end

local function UpdateSpellStatus(button, spellID)
button.Icon:SetTexture(GetSpellTexture(spellID))
if IsUsableSpell(spellID) then
if C_Spell.IsSpellUsable(spellID) then
button.Icon:SetDesaturated(false)
else
button.Icon:SetDesaturated(true)
Expand Down
Loading

0 comments on commit 7608800

Please sign in to comment.