- Added option to disable the mythic dungeon damage chart.
- Removed debug chat messages from the dungeon chart. - Framework update to v67.
This commit is contained in:
+16
-6
@@ -1,5 +1,5 @@
|
||||
|
||||
local dversion = 66
|
||||
local dversion = 67
|
||||
local major, minor = "DetailsFramework-1.0", dversion
|
||||
local DF, oldminor = LibStub:NewLibrary (major, minor)
|
||||
|
||||
@@ -999,11 +999,15 @@ end
|
||||
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
--> templates
|
||||
|
||||
DF.font_templates = {}
|
||||
--fonts
|
||||
|
||||
DF.font_templates = DF.font_templates or {}
|
||||
DF.font_templates ["ORANGE_FONT_TEMPLATE"] = {color = "orange", size = 11, font = "Accidental Presidency"}
|
||||
DF.font_templates ["OPTIONS_FONT_TEMPLATE"] = {color = "yellow", size = 12, font = "Accidental Presidency"}
|
||||
|
||||
DF.dropdown_templates = {}
|
||||
-- dropdowns
|
||||
|
||||
DF.dropdown_templates = DF.dropdown_templates or {}
|
||||
DF.dropdown_templates ["OPTIONS_DROPDOWN_TEMPLATE"] = {
|
||||
backdrop = {edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true},
|
||||
backdropcolor = {1, 1, 1, .5},
|
||||
@@ -1012,7 +1016,9 @@ DF.dropdown_templates ["OPTIONS_DROPDOWN_TEMPLATE"] = {
|
||||
onenterbordercolor = {1, 1, 1, 1},
|
||||
}
|
||||
|
||||
DF.switch_templates = {}
|
||||
-- switches
|
||||
|
||||
DF.switch_templates = DF.switch_templates or {}
|
||||
DF.switch_templates ["OPTIONS_CHECKBOX_TEMPLATE"] = {
|
||||
backdrop = {edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true},
|
||||
backdropcolor = {1, 1, 1, .5},
|
||||
@@ -1034,14 +1040,18 @@ DF.switch_templates ["OPTIONS_CHECKBOX_BRIGHT_TEMPLATE"] = {
|
||||
onenterbordercolor = {1, 1, 1, 1},
|
||||
}
|
||||
|
||||
DF.button_templates = {}
|
||||
-- buttons
|
||||
|
||||
DF.button_templates = DF.button_templates or {}
|
||||
DF.button_templates ["OPTIONS_BUTTON_TEMPLATE"] = {
|
||||
backdrop = {edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true},
|
||||
backdropcolor = {1, 1, 1, .5},
|
||||
backdropbordercolor = {0, 0, 0, 1},
|
||||
}
|
||||
|
||||
DF.slider_templates = {}
|
||||
-- sliders
|
||||
|
||||
DF.slider_templates = DF.slider_templates or {}
|
||||
DF.slider_templates ["OPTIONS_SLIDER_TEMPLATE"] = {
|
||||
backdrop = {edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true},
|
||||
backdropcolor = {1, 1, 1, .5},
|
||||
|
||||
+33
-18
@@ -6,7 +6,7 @@
|
||||
|
||||
--local pointer to details object
|
||||
local Details = _G._detalhes
|
||||
local debugmode = true
|
||||
local debugmode = false
|
||||
|
||||
--constants
|
||||
local CONST_USE_PLAYER_EDPS = false
|
||||
@@ -166,8 +166,6 @@ function mythicDungeonCharts:OnBossDefeated()
|
||||
local segmentType = currentCombat:GetCombatType()
|
||||
local bossInfo = currentCombat:GetBossInfo()
|
||||
|
||||
print (mythicDungeonCharts.ChartTable, mythicDungeonCharts.ChartTable.Running, segmentType, bossInfo)
|
||||
|
||||
if (mythicDungeonCharts.ChartTable and mythicDungeonCharts.ChartTable.Running and bossInfo) then
|
||||
|
||||
local copiedBossInfo = Details:GetFramework().table.copy ({}, bossInfo)
|
||||
@@ -214,7 +212,10 @@ function mythicDungeonCharts:OnStartMythicDungeon()
|
||||
|
||||
mythicDungeonCharts.ChartTable.Ticker = C_Timer.NewTicker (1, tickerCallback)
|
||||
|
||||
_detalhes.mythic_plus.last_mythicrun_chart = mythicDungeonCharts.ChartTable
|
||||
--save the chart for development
|
||||
if (debugmode) then
|
||||
_detalhes.mythic_plus.last_mythicrun_chart = mythicDungeonCharts.ChartTable
|
||||
end
|
||||
end
|
||||
|
||||
function mythicDungeonCharts:OnEndMythicDungeon()
|
||||
@@ -229,7 +230,7 @@ function mythicDungeonCharts:OnEndMythicDungeon()
|
||||
|
||||
mythicDungeonCharts:Debug ("Dungeon ended, chart data capture stopped")
|
||||
|
||||
mythicDungeonCharts.ShowChart()
|
||||
C_Timer.After (_detalhes.mythic_plus.delay_to_show_graphic or 5, mythicDungeonCharts.ShowChart)
|
||||
else
|
||||
mythicDungeonCharts:Debug ("Dungeon ended, no chart data was running")
|
||||
end
|
||||
@@ -277,6 +278,13 @@ function mythicDungeonCharts.ShowChart()
|
||||
f.BossWidgetsFrame:SetFrameLevel (f:GetFrameLevel()+10)
|
||||
f.BossWidgetsFrame.Widgets = {}
|
||||
|
||||
local closeButton = CreateFrame ("button", "$parentCloseButton", f, "UIPanelCloseButton")
|
||||
closeButton:GetNormalTexture():SetDesaturated (true)
|
||||
closeButton:SetWidth (20)
|
||||
closeButton:SetHeight (20)
|
||||
closeButton:SetPoint ("topright", f, "topright", 0, -3)
|
||||
closeButton:SetFrameLevel (f:GetFrameLevel()+16)
|
||||
|
||||
function f.ChartFrame.RefreshBossTimeline (self, bossTable, elapsedTime)
|
||||
|
||||
for i, bossTable in ipairs (mythicDungeonCharts.ChartTable.BossDefeated) do
|
||||
@@ -328,14 +336,20 @@ function mythicDungeonCharts.ShowChart()
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
|
||||
mythicDungeonCharts.Frame.ChartFrame:Reset()
|
||||
|
||||
if (not mythicDungeonCharts.ChartTable) then
|
||||
--load the last mythic dungeon run chart
|
||||
local t = {}
|
||||
Details:GetFramework().table.copy (t, Details.mythic_plus.last_mythicrun_chart)
|
||||
mythicDungeonCharts.ChartTable = t
|
||||
if (not mythicDungeonCharts.ChartTable and debugmode) then
|
||||
--development
|
||||
if (Details.mythic_plus.last_mythicrun_chart) then
|
||||
--load the last mythic dungeon run chart
|
||||
local t = {}
|
||||
Details:GetFramework().table.copy (t, Details.mythic_plus.last_mythicrun_chart)
|
||||
mythicDungeonCharts.ChartTable = t
|
||||
end
|
||||
else
|
||||
f:Hide()
|
||||
return
|
||||
end
|
||||
|
||||
local charts = mythicDungeonCharts.ChartTable.Players
|
||||
@@ -394,7 +408,6 @@ function mythicDungeonCharts.ShowChart()
|
||||
--]=]
|
||||
end
|
||||
|
||||
|
||||
mythicDungeonCharts.Frame.ChartFrame:RefreshBossTimeline (mythicDungeonCharts.ChartTable.BossDefeated, mythicDungeonCharts.ChartTable.ElapsedTime)
|
||||
|
||||
--generate boss time table
|
||||
@@ -406,17 +419,19 @@ function mythicDungeonCharts.ShowChart()
|
||||
tinsert (bossTimeTable, bossTable[1] - combatTime)
|
||||
end
|
||||
|
||||
mythicDungeonCharts.Frame.ChartFrame:AddOverlay (bossTimeTable, {1, 1, 1, 0.05}, "Boss Combat Time", "")
|
||||
mythicDungeonCharts.Frame.ChartFrame:AddOverlay (bossTimeTable, {1, 1, 1, 0.05}, "Show Boss", "")
|
||||
|
||||
--local phrase = " Average Dps (under development)\npress Escape to hide, Details! Alpha Build." .. _detalhes.build_counter .. "." .. _detalhes.realversion
|
||||
local phrase = "Details!: Average Dps for "
|
||||
|
||||
local phrase = " Average Dps (under development)\npress Escape to hide, Details! Alpha Build." .. _detalhes.build_counter .. "." .. _detalhes.realversion
|
||||
|
||||
mythicDungeonCharts.Frame.ChartFrame:SetTitle (mythicDungeonCharts.ChartTable.DungeonName and mythicDungeonCharts.ChartTable.DungeonName .. phrase or phrase)
|
||||
mythicDungeonCharts.Frame.ChartFrame:SetTitle (mythicDungeonCharts.ChartTable.DungeonName and phrase .. mythicDungeonCharts.ChartTable.DungeonName or phrase)
|
||||
Details:GetFramework():SetFontSize (mythicDungeonCharts.Frame.ChartFrame.chart_title, 14)
|
||||
|
||||
|
||||
mythicDungeonCharts.Frame:Show()
|
||||
end
|
||||
|
||||
--C_Timer.After (1, mythicDungeonCharts.ShowChart)
|
||||
if (debugmode) then
|
||||
C_Timer.After (1, mythicDungeonCharts.ShowChart)
|
||||
end
|
||||
|
||||
-- endd
|
||||
|
||||
@@ -1308,6 +1308,7 @@ local default_global_data = {
|
||||
make_overall_when_done = true, --
|
||||
make_overall_boss_only = false, --
|
||||
show_damage_graphic = true,
|
||||
delay_to_show_graphic = 5,
|
||||
last_mythicrun_chart = {},
|
||||
mythicrun_chart_frame = {},
|
||||
},
|
||||
|
||||
@@ -2483,6 +2483,19 @@ function window:CreateFrame18()
|
||||
|
||||
window:CreateLineBackground2 (frame18, "DisableMythicDungeonSlider", "DisableMythicDungeonLabel", "Threat mythic dungeon segments as common segments: no trash merge, no mythic run overall, segments wraps on entering and leaving combat.")
|
||||
|
||||
--> disable chart at the end of a mythic dungeon
|
||||
g:NewLabel (frame18, _, "$parentDisableMythicDungeonChartLabel", "DisableMythicDungeonChartLabel", "Show Mythic Dungeon Damage Graphic", "GameFontHighlightLeft")
|
||||
g:NewSwitch (frame18, _, "$parentDisableMythicDungeonChartSlider", "DisableMythicDungeonChartSlider", 60, 20, _, _, _detalhes.mythic_plus.show_damage_graphic, nil, nil, nil, nil, options_switch_template)
|
||||
|
||||
frame18.DisableMythicDungeonChartSlider:SetPoint ("left", frame18.DisableMythicDungeonChartLabel, "right", 2)
|
||||
frame18.DisableMythicDungeonChartSlider:SetAsCheckBox()
|
||||
frame18.DisableMythicDungeonChartSlider.OnSwitch = function (_, _, value)
|
||||
_detalhes.mythic_plus.show_damage_graphic = not _detalhes.mythic_plus.show_damage_graphic
|
||||
_detalhes:SendOptionsModifiedEvent (DetailsOptionsWindow.instance)
|
||||
end
|
||||
|
||||
window:CreateLineBackground2 (frame18, "DisableMythicDungeonChartSlider", "DisableMythicDungeonChartLabel", "At the end of a mythic dungeon run, show a graphic with the DPS of each player.")
|
||||
|
||||
--> clear cache
|
||||
g:NewLabel (frame18, _, "$parentClearCacheLabel", "ClearCacheLabel", "Clear Cache on New Event", "GameFontHighlightLeft")
|
||||
g:NewSwitch (frame18, _, "$parentClearCacheSlider", "ClearCacheSlider", 60, 20, _, _, _detalhes.streamer_config.reset_spec_cache, nil, nil, nil, nil, options_switch_template)
|
||||
@@ -2544,6 +2557,7 @@ function window:CreateFrame18()
|
||||
{"FasterUpdatesLabel"},
|
||||
{"QuickDetectionLabel"},
|
||||
{"DisableMythicDungeonLabel"},
|
||||
{"DisableMythicDungeonChartLabel"},
|
||||
{"ClearCacheLabel"},
|
||||
--{"AdvancedAnimationsLabel"},
|
||||
}
|
||||
@@ -11668,6 +11682,7 @@ end --> if not window
|
||||
_G.DetailsOptionsWindow18FasterUpdatesSlider.MyObject:SetValue (_detalhes.streamer_config.faster_updates)
|
||||
_G.DetailsOptionsWindow18QuickDetectionSlider.MyObject:SetValue (_detalhes.streamer_config.quick_detection)
|
||||
_G.DetailsOptionsWindow18DisableMythicDungeonSlider.MyObject:SetValue (_detalhes.streamer_config.disable_mythic_dungeon)
|
||||
_G.DetailsOptionsWindow18DisableMythicDungeonChartSlider.MyObject:SetValue (_detalhes.mythic_plus.show_damage_graphic)
|
||||
_G.DetailsOptionsWindow18ClearCacheSlider.MyObject:SetValue (_detalhes.streamer_config.reset_spec_cache)
|
||||
--_G.DetailsOptionsWindow18AdvancedAnimationsSlider.MyObject:SetValue (_detalhes.streamer_config.use_animation_accel)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user