Skip to content

Commit 89bf3a5

Browse files
committed
Fixed Streamer plugin bug
1 parent 9403ef1 commit 89bf3a5

File tree

3 files changed

+22
-6
lines changed

3 files changed

+22
-6
lines changed

boot.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
local addonName, Details222 = ...
2020
local version, build, date, tvs = GetBuildInfo()
2121

22-
Details.build_counter = 12878
23-
Details.alpha_build_counter = 12878 --if this is higher than the regular counter, use it instead
22+
Details.build_counter = 12879
23+
Details.alpha_build_counter = 12879 --if this is higher than the regular counter, use it instead
2424
Details.dont_open_news = true
2525
Details.game_version = version
2626
Details.userversion = version .. " " .. Details.build_counter

plugins/Details_Compare2/Details_Compare2.lua

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
11

22
do
3+
local _
34
local Details = Details
5+
46
if (not Details) then
57
print("Details! Not Found.")
68
return
79
end
810

11+
---@type detailsframework
12+
local detailsFramework = DetailsFramework
13+
914
local CONST_COMPARETYPE_SPEC = 1
1015
local CONST_COMPARETYPE_SEGMENT = 2
1116

@@ -150,9 +155,6 @@ do
150155
--> create a plugin object
151156
local compareTwo = Details:NewPluginObject("Details_Compare2", _G.DETAILSPLUGIN_ALWAYSENABLED)
152157

153-
---@type detailsframework
154-
local detailsFramework = DetailsFramework
155-
156158
--> set the description
157159
compareTwo:SetPluginDescription("Replaces the default comparison window on the player breakdown.")
158160

@@ -1932,12 +1934,15 @@ do
19321934
newComparisonFrame.titleIcon = detailsFramework:CreateTexture(newComparisonFrame)
19331935
newComparisonFrame.titleIcon:SetPoint("topleft", newComparisonFrame, "topleft", 0, comparisonFrameSettings.playerNameYOffset)
19341936

1935-
--player name shown above the scrolls
1937+
--player name or segment name shown above the scrolls
19361938
---@type df_label
19371939
newComparisonFrame.titleLabel = detailsFramework:CreateLabel(newComparisonFrame, "")
19381940
newComparisonFrame.titleLabel:SetPoint("left", newComparisonFrame.titleIcon, "right", 2, 0)
19391941
newComparisonFrame.titleLabel.fontsize = comparisonFrameSettings.playerNameSize
19401942

1943+
--combat selector dropdown
1944+
--todo: create a dropdown to select the combat
1945+
19411946
--grandient texture above the comparison frame
19421947
local gradientTitle = detailsFramework:CreateTexture(newComparisonFrame, {gradient = "vertical", fromColor = {0, 0, 0, 0.25}, toColor = "transparent"}, 1, 16, "artwork", {0, 1, 0, 1})
19431948
gradientTitle:SetPoint("bottomleft", newComparisonFrame, "topleft", 0, 0)

plugins/Details_Streamer/Details_Streamer.lua

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,17 @@ local iconSize = 16
6161
--default icon for an attack on a monster
6262
local defaultAttackIcon = [[Interface\CURSOR\UnableAttack]]
6363

64+
local GetSpellInfo = GetSpellInfo
65+
66+
if (C_Spell and C_Spell.GetSpellInfo) then
67+
GetSpellInfo = function(spellId)
68+
local spellInfo = C_Spell.GetSpellInfo(spellId)
69+
if (spellInfo) then
70+
return spellInfo.name, _, spellInfo.iconID
71+
end
72+
end
73+
end
74+
6475
local function CreatePluginFrames()
6576
--shortcut for details fade function
6677
local fader = Details.FadeHandler.Fader

0 commit comments

Comments
 (0)