- Death Knight: Epidemic, Scourge Strike and Howling Blast now has a better description on the spell name.

- Fixed snap button showing when 'Hide Resize Buttons' are enabled.
- Fixed title bar icons not hiding when 'Auto Hide Buttons' is enabled.
- Several improvements to overall data, it should be more consistent now.
- Details! now passes to identify the tank role of the player even when out of a party or raid.
- Debug helper Details:DumpTable(table) now correctly shows the key name when it isn't a string.
- Improvements done on the Bookmark config frame accessed by the options panel > display section.
- New slash command: '/details spells'.
- Statistics for Legion has been closed! You can access statistics from the orange gear > statistics.
This commit is contained in:
Tercio
2018-08-07 15:55:19 -03:00
parent 5f55045b15
commit 2fb29a497d
45 changed files with 848 additions and 679 deletions
+12 -1
View File
@@ -1149,8 +1149,17 @@ end
local pickcolor_callback = function (self, r, g, b, a, button)
a = abs (a-1)
button.MyObject.color_texture:SetVertexColor (r, g, b, a)
button.MyObject:color_callback (r, g, b, a)
--> safecall
--button.MyObject:color_callback (r, g, b, a)
local success, errorText = pcall (button.MyObject.color_callback, button.MyObject, r, g, b, a)
if (not success) then
error ("Details! Framework: colorpick " .. (self:GetName() or "-NONAME-") .. " error: " .. errorText)
end
button.MyObject:RunHooksForWidget ("OnColorChanged", button.MyObject, r, g, b, a)
end
local pickcolor = function (self, alpha, param2)
local r, g, b, a = self.MyObject.color_texture:GetVertexColor()
a = abs (a-1)
@@ -1181,6 +1190,8 @@ function DF:NewColorPickButton (parent, name, member, callback, alpha, button_te
button.Cancel = colorpick_cancel
button.SetColor = set_colorpick_color
button.HookList.OnColorChanged = {}
if (not button_template) then
button:InstallCustomTexture()
button:SetBackdrop ({edgeFile = [[Interface\Tooltips\UI-Tooltip-Border]], edgeSize = 6,
+7 -5
View File
@@ -490,7 +490,7 @@ function DetailsFrameworkDropDownOptionClick (button)
error ("Details! Framework: dropdown " .. button:GetParent():GetParent():GetParent().MyObject:GetName() .. " error: " .. errorText)
end
--button.table.onclick (button:GetParent():GetParent():GetParent().MyObject, button.object.FixedValue, button.table.value)
button:GetParent():GetParent():GetParent().MyObject:RunHooksForWidget ("OnOptionSelected", button:GetParent():GetParent():GetParent().MyObject, button.object.FixedValue, button.table.value)
end
--> set the value of selected option in main object
@@ -987,7 +987,8 @@ function DF:NewDropDown (parent, container, name, member, w, h, func, default, t
local scroll = _G [DropDownObject.dropdown:GetName() .. "_ScrollFrame"]
DropDownObject.scroll = DF:NewScrollBar (scroll, _G [DropDownObject.dropdown:GetName() .. "_ScrollFrame".."_ScrollChild"], -25, -18)
DropDownObject.scroll = DF:NewScrollBar (scroll, _G [DropDownObject.dropdown:GetName() .. "_ScrollFrame".."_ScrollChild"], -18, -18)
DF:ReskinSlider (scroll)
function DropDownObject:HideScroll()
scroll.baixo:Hide()
@@ -1000,8 +1001,6 @@ function DF:NewDropDown (parent, container, name, member, w, h, func, default, t
scroll.slider:Show()
end
--button_down_scripts (DropDownObject, scroll.slider, scroll.baixo)
DropDownObject:HideScroll()
DropDownObject.label:SetSize (DropDownObject.dropdown:GetWidth()-40, 10)
@@ -1010,6 +1009,7 @@ function DF:NewDropDown (parent, container, name, member, w, h, func, default, t
OnLeave = {},
OnHide = {},
OnShow = {},
OnOptionSelected = {},
}
DropDownObject.dropdown:SetScript ("OnShow", DetailsFrameworkDropDownOnShow)
@@ -1110,13 +1110,15 @@ function DF:CreateNewDropdownFrame (parent, name)
scroll:SetSize (150, 150)
scroll:SetPoint ("topleft", f, "bottomleft", 0, 0)
f.dropdownframe = scroll
local child = CreateFrame ("frame", "$Parent_ScrollChild", scroll)
child:SetSize (150, 150)
child:SetPoint ("topleft", scroll, "topleft", 0, 0)
child:SetBackdrop (child_backdrop)
child:SetBackdropColor (0, 0, 0, 1)
DF:ApplyStandardBackdrop (child)
local selected = child:CreateTexture ("$parent_SelectedTexture", "BACKGROUND")
selected:SetSize (150, 16)
selected:Hide()
+248 -24
View File
@@ -1,5 +1,5 @@
local dversion = 87
local dversion = 94
local major, minor = "DetailsFramework-1.0", dversion
local DF, oldminor = LibStub:NewLibrary (major, minor)
@@ -122,10 +122,12 @@ local embed_functions = {
"FormatNumber",
"IntegerToTimer",
"QuickDispatch",
"Dispatch",
"CommaValue",
"RemoveRealmName",
"Trim",
"CreateGlowOverlay",
"CreateAnts",
"CreateFrameShake",
}
@@ -696,7 +698,7 @@ end
local disable_on_combat = {}
function DF:BuildMenu (parent, menu, x_offset, y_offset, height, use_two_points, text_template, dropdown_template, switch_template, switch_is_box, slider_template, button_template)
function DF:BuildMenu (parent, menu, x_offset, y_offset, height, use_two_points, text_template, dropdown_template, switch_template, switch_is_box, slider_template, button_template, value_change_hook)
if (not parent.widget_list) then
DF:SetAsOptionsPanel (parent)
@@ -734,6 +736,18 @@ end
dropdown:SetPoint ("left", label, "right", 2)
label:SetPoint (cur_x, cur_y)
--> global callback
if (value_change_hook) then
dropdown:SetHook ("OnOptionSelected", value_change_hook)
end
--> hook list
if (widget_table.hooks) then
for hookName, hookFunc in pairs (widget_table.hooks) do
dropdown:SetHook (hookName, hookFunc)
end
end
local size = label.widget:GetStringWidth() + 140 + 4
if (size > max_x) then
max_x = size
@@ -754,6 +768,17 @@ end
switch:SetAsCheckBox()
end
if (value_change_hook) then
switch:SetHook ("OnSwitch", value_change_hook)
end
--> hook list
if (widget_table.hooks) then
for hookName, hookFunc in pairs (widget_table.hooks) do
switch:SetHook (hookName, hookFunc)
end
end
local label = DF:NewLabel (parent, nil, "$parentLabel" .. index, nil, widget_table.name .. (use_two_points and ": " or ""), "GameFontNormal", widget_table.text_template or text_template or 12)
switch:SetPoint ("left", label, "right", 2)
label:SetPoint (cur_x, cur_y)
@@ -777,6 +802,19 @@ end
if (widget_table.thumbscale) then
slider:SetThumbSize (slider.thumb:GetWidth()*widget_table.thumbscale, nil)
else
slider:SetThumbSize (slider.thumb:GetWidth()*1.3, nil)
end
if (value_change_hook) then
slider:SetHook ("OnValueChanged", value_change_hook)
end
--> hook list
if (widget_table.hooks) then
for hookName, hookFunc in pairs (widget_table.hooks) do
slider:SetHook (hookName, hookFunc)
end
end
local label = DF:NewLabel (parent, nil, "$parentLabel" .. index, nil, widget_table.name .. (use_two_points and ": " or ""), "GameFontNormal", widget_table.text_template or text_template or 12)
@@ -805,6 +843,17 @@ end
colorpick:SetColor (default_value, g, b, a)
end
if (value_change_hook) then
colorpick:SetHook ("OnColorChanged", value_change_hook)
end
--> hook list
if (widget_table.hooks) then
for hookName, hookFunc in pairs (widget_table.hooks) do
colorpick:SetHook (hookName, hookFunc)
end
end
local label = DF:NewLabel (parent, nil, "$parentLabel" .. index, nil, widget_table.name .. (use_two_points and ": " or ""), "GameFontNormal", widget_table.text_template or text_template or 12)
colorpick:SetPoint ("left", label, "right", 2)
label:SetPoint (cur_x, cur_y)
@@ -829,6 +878,15 @@ end
button.tooltip = widget_table.desc
button.widget_type = "execute"
--> execute doesn't trigger global callback
--> hook list
if (widget_table.hooks) then
for hookName, hookFunc in pairs (widget_table.hooks) do
button:SetHook (hookName, hookFunc)
end
end
local size = button:GetWidth() + 4
if (size > max_x) then
max_x = size
@@ -851,6 +909,15 @@ end
textentry:SetPoint ("left", label, "right", 2)
label:SetPoint (cur_x, cur_y)
--> text entry doesn't trigger global callback
--> hook list
if (widget_table.hooks) then
for hookName, hookFunc in pairs (widget_table.hooks) do
textentry:SetHook (hookName, hookFunc)
end
end
local size = label.widget:GetStringWidth() + 60 + 4
if (size > max_x) then
max_x = size
@@ -1130,8 +1197,43 @@ end
--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"}
--> detect which language is the client and select the font accordingly
local clientLanguage = GetLocale()
if (clientLanguage == "enGB") then
clientLanguage = "enUS"
end
DF.ClientLanguage = clientLanguage
--> return the best font to use for the client language
function DF:GetBestFontForLanguage (language, western, cyrillic, china, korean, taiwan)
if (not language) then
language = DF.ClientLanguage
end
if (language == "enUS" or language == "deDE" or language == "esES" or language == "esMX" or language == "frFR" or language == "itIT" or language == "ptBR") then
return western or "Accidental Presidency"
elseif (language == "ruRU") then
return cyrillic or "Arial Narrow"
elseif (language == "zhCN") then
return china or "AR CrystalzcuheiGBK Demibold"
elseif (language == "koKR") then
return korean or "2002"
elseif (language == "zhTW") then
return taiwan or "AR CrystalzcuheiGBK Demibold"
end
end
--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.font_templates ["ORANGE_FONT_TEMPLATE"] = {color = "orange", size = 11, font = DF:GetBestFontForLanguage()}
DF.font_templates ["OPTIONS_FONT_TEMPLATE"] = {color = "yellow", size = 12, font = DF:GetBestFontForLanguage()}
-- dropdowns
@@ -1212,6 +1314,14 @@ function DF:InstallTemplate (widget_type, template_name, template, parent_name)
local template_table
if (widget_type == "font") then
template_table = DF.font_templates
local font = template.font
if (font) then
--> fonts passed into the template has default to western
--> the framework will get the game client language and change the font if needed
font = DF:GetBestFontForLanguage (nil, font)
end
elseif (widget_type == "dropdown") then
template_table = DF.dropdown_templates
elseif (widget_type == "button") then
@@ -1260,7 +1370,7 @@ function DF:RunHooksForWidget (event, ...)
local hooks = self.HookList [event]
if (not hooks) then
print (self.widget:GetName(), "sem hook para", event)
print (self.widget:GetName(), "no hooks for", event)
return
end
@@ -1397,6 +1507,7 @@ function DF:CreateAnimationHub (parent, onPlay, onFinished)
local newAnimation = parent:CreateAnimationGroup()
newAnimation:SetScript ("OnPlay", onPlay)
newAnimation:SetScript ("OnFinished", onFinished)
newAnimation:SetScript ("OnStop", onFinished)
newAnimation.NextAnimation = 1
return newAnimation
end
@@ -1434,6 +1545,9 @@ end
local frameshake_shake_finished = function (parent, shakeObject)
if (shakeObject.IsPlaying) then
shakeObject.IsPlaying = false
shakeObject.TimeLeft = 0
shakeObject.IsFadingOut = false
shakeObject.IsFadingIn = false
--> update the amount of shake running on this frame
parent.__frameshakes.enabled = parent.__frameshakes.enabled - 1
@@ -1442,7 +1556,18 @@ local frameshake_shake_finished = function (parent, shakeObject)
for i = 1, #shakeObject.Anchors do
local anchor = shakeObject.Anchors [i]
if (#anchor == 3) then
--> automatic anchoring and reanching needs to the reviwed in the future
if (#anchor == 1) then
local anchorTo = unpack (anchor)
parent:ClearAllPoints()
parent:SetPoint (anchorTo)
elseif (#anchor == 2) then
local anchorTo, point1 = unpack (anchor)
parent:ClearAllPoints()
parent:SetPoint (anchorTo, point1)
elseif (#anchor == 3) then
local anchorTo, point1, point2 = unpack (anchor)
parent:SetPoint (anchorTo, point1, point2)
@@ -1461,9 +1586,8 @@ local frameshake_do_update = function (parent, shakeObject, deltaTime)
--> update time left
shakeObject.TimeLeft = max (shakeObject.TimeLeft - deltaTime, 0)
if (shakeObject.TimeLeft > 0) then
--> update fade in and out
if (shakeObject.IsFadingIn) then
shakeObject.IsFadingInTime = shakeObject.IsFadingInTime + deltaTime
@@ -1485,7 +1609,7 @@ local frameshake_do_update = function (parent, shakeObject, deltaTime)
--> update position
local scaleShake = min (shakeObject.IsFadingIn and (shakeObject.IsFadingInTime / shakeObject.FadeInTime) or 1, shakeObject.IsFadingOut and (1 - shakeObject.IsFadingOutTime / shakeObject.FadeOutTime) or 1)
if (scaleShake > 0) then
--> delate the time by the frequency on both X and Y offsets
@@ -1511,12 +1635,16 @@ local frameshake_do_update = function (parent, shakeObject, deltaTime)
for i = 1, #shakeObject.Anchors do
local anchor = shakeObject.Anchors [i]
if (#anchor == 3) then
if (#anchor == 1 or #anchor == 3) then
local anchorTo, point1, point2 = unpack (anchor)
point1 = point1 or 0
point2 = point2 or 0
parent:SetPoint (anchorTo, point1 + newX, point2 + newY)
elseif (#anchor == 5) then
local anchorName1, anchorTo, anchorName2, point1, point2 = unpack (anchor)
--parent:ClearAllPoints()
parent:SetPoint (anchorName1, anchorTo, anchorName2, point1 + newX, point2 + newY)
end
end
@@ -1541,6 +1669,10 @@ local frameshake_update_all = function (parent, deltaTime)
end
end
local frameshake_stop = function (parent, shakeObject)
frameshake_shake_finished (parent, shakeObject)
end
--> scale direction scales the X and Y coordinates, scale strength scales the amplitude and frequency
local frameshake_play = function (parent, shakeObject, scaleDirection, scaleAmplitude, scaleFrequency, scaleDuration)
@@ -1563,7 +1695,6 @@ local frameshake_play = function (parent, shakeObject, scaleDirection, scaleAmpl
shakeObject.IsFadingOut = false
shakeObject.IsFadingOutTime = 0
end
else
--> create a new random offset
shakeObject.XSineOffset = math.pi * 2 * math.random()
@@ -1605,6 +1736,10 @@ local frameshake_play = function (parent, shakeObject, scaleDirection, scaleAmpl
--> update the amount of shake running on this frame
parent.__frameshakes.enabled = parent.__frameshakes.enabled + 1
if (not parent:GetScript ("OnUpdate")) then
parent:SetScript ("OnUpdate", function()end)
end
end
shakeObject.IsPlaying = true
@@ -1649,6 +1784,7 @@ function DF:CreateFrameShake (parent, duration, amplitude, frequency, absoluteSi
enabled = 0,
}
parent.PlayFrameShake = frameshake_play
parent.StopFrameShake = frameshake_stop
parent.UpdateFrameShake = frameshake_do_update
parent.UpdateAllFrameShake = frameshake_update_all
parent:HookScript ("OnUpdate", frameshake_update_all)
@@ -1663,28 +1799,69 @@ end
-----------------------------
--> glow overlay
local play_glow_overlay = function (self)
self:Show()
local glow_overlay_play = function (self)
if (not self:IsShown()) then
self:Show()
end
if (self.animOut:IsPlaying()) then
self.animOut:Stop()
end
self.animIn:Play()
if (not self.animIn:IsPlaying()) then
self.animIn:Play()
end
end
local stop_glow_overlay = function (self)
self.animOut:Stop()
self.animIn:Stop()
self:Hide()
local glow_overlay_stop = function (self)
if (self.animOut:IsPlaying()) then
self.animOut:Stop()
end
if (self.animIn:IsPlaying()) then
self.animIn:Stop()
end
if (self:IsShown()) then
self:Hide()
end
end
local defaultColor = {1, 1, 1, 1}
local glow_overlay_setcolor = function (self, antsColor, glowColor)
if (antsColor) then
local r, g, b, a = DF:ParseColors (antsColor)
self.ants:SetVertexColor (r, g, b, a)
self.AntsColor.r = r
self.AntsColor.g = g
self.AntsColor.b = b
self.AntsColor.a = a
end
if (glowColor) then
local r, g, b, a = DF:ParseColors (glowColor)
self.outerGlow:SetVertexColor (r, g, b, a)
self.GlowColor.r = r
self.GlowColor.g = g
self.GlowColor.b = b
self.GlowColor.a = a
end
end
local glow_overlay_onshow = function (self)
glow_overlay_play (self)
end
local glow_overlay_onhide = function (self)
glow_overlay_stop (self)
end
--this is most copied from the wow client code, few changes applied to customize it
function DF:CreateGlowOverlay (parent, antsColor, glowColor)
local glowFrame = CreateFrame ("frame", parent:GetName() and "$parentGlow2" or "OverlayActionGlow" .. math.random (1, 10000000), parent, "ActionBarButtonSpellActivationAlert")
glowFrame:HookScript ("OnShow", glow_overlay_onshow)
glowFrame:HookScript ("OnHide", glow_overlay_onhide)
glowFrame.Play = play_glow_overlay
glowFrame.Stop = stop_glow_overlay
glowFrame.Play = glow_overlay_play
glowFrame.Stop = glow_overlay_stop
glowFrame.SetColor = glow_overlay_setcolor
glowFrame:Hide()
parent.overlay = glowFrame
local frameWidth, frameHeight = parent:GetSize()
@@ -1693,20 +1870,67 @@ function DF:CreateGlowOverlay (parent, antsColor, glowColor)
--Make the height/width available before the next frame:
parent.overlay:SetSize(frameWidth * scale, frameHeight * scale)
parent.overlay:SetPoint("TOPLEFT", parent, "TOPLEFT", -frameWidth * 0.2, frameHeight * 0.2)
parent.overlay:SetPoint("BOTTOMRIGHT", parent, "BOTTOMRIGHT", frameWidth * 0.2, -frameHeight * 0.2)
parent.overlay:SetPoint("TOPLEFT", parent, "TOPLEFT", -frameWidth * 0.32, frameHeight * 0.36)
parent.overlay:SetPoint("BOTTOMRIGHT", parent, "BOTTOMRIGHT", frameWidth * 0.32, -frameHeight * 0.36)
local r, g, b, a = DF:ParseColors (antsColor or defaultColor)
glowFrame.ants:SetVertexColor (r, g, b, a)
glowFrame.AntsColor = {r, g, b, a}
local r, g, b, a = DF:ParseColors (glowColor or defaultColor)
glowFrame.outerGlow:SetVertexColor (r, g, b, a)
glowFrame.GlowColor = {r, g, b, a}
glowFrame.outerGlow:SetScale (1.2)
return glowFrame
end
--> custom glow with ants animation
local ants_set_texture_offset = function (self, leftOffset, rightOffset, topOffset, bottomOffset)
leftOffset = leftOffset or 0
rightOffset = rightOffset or 0
topOffset = topOffset or 0
bottomOffset = bottomOffset or 0
self:ClearAllPoints()
self:SetPoint ("topleft", leftOffset, topOffset)
self:SetPoint ("bottomright", rightOffset, bottomOffset)
end
function DF:CreateAnts (parent, antTable, leftOffset, rightOffset, topOffset, bottomOffset, antTexture)
leftOffset = leftOffset or 0
rightOffset = rightOffset or 0
topOffset = topOffset or 0
bottomOffset = bottomOffset or 0
local f = CreateFrame ("frame", nil, parent)
f:SetPoint ("topleft", leftOffset, topOffset)
f:SetPoint ("bottomright", rightOffset, bottomOffset)
f.SetOffset = ants_set_texture_offset
local t = f:CreateTexture (nil, "overlay")
t:SetAllPoints()
t:SetTexture (antTable.Texture)
t:SetBlendMode (antTable.BlendMode or "ADD")
t:SetVertexColor (DF:ParseColors (antTable.Color or "white"))
f.Texture = t
f.AntTable = antTable
f:SetScript ("OnUpdate", function (self, deltaTime)
AnimateTexCoords (t, self.AntTable.TextureWidth, self.AntTable.TextureHeight, self.AntTable.TexturePartsWidth, self.AntTable.TexturePartsHeight, self.AntTable.AmountParts, deltaTime, self.AntTable.Throttle or 0.025)
end)
return f
end
--[=[ --test ants
do
local f = DF:CreateAnts (UIParent)
end
--]=]
-----------------------------
--> borders
+48 -22
View File
@@ -38,6 +38,10 @@ DF.OptionsFunctions = {
self.options = {}
self.options [optionName] = optionValue
end
if (self.OnOptionChanged) then
DF:Dispatch (self.OnOptionChanged, self, optionName, optionValue)
end
end,
GetOption = function (self, optionName)
@@ -2067,34 +2071,42 @@ function DF:ShowTextPromptPanel (message, callback)
if (not DF.text_prompt_panel) then
local f = CreateFrame ("frame", "DetailsFrameworkPrompt", UIParent)
f:SetSize (400, 100)
f:SetFrameStrata ("DIALOG")
f:SetPoint ("center", UIParent, "center", 0, 300)
f:SetBackdrop ({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
f:SetBackdropColor (0, 0, 0, 0.8)
f:SetBackdropBorderColor (0, 0, 0, 1)
f:SetSize (400, 120)
f:SetFrameStrata ("FULLSCREEN")
f:SetPoint ("center", UIParent, "center", 0, 100)
f:EnableMouse (true)
f:SetMovable (true)
f:RegisterForDrag ("LeftButton")
f:SetScript ("OnDragStart", function() f:StartMoving() end)
f:SetScript ("OnDragStop", function() f:StopMovingOrSizing() end)
f:SetScript ("OnMouseDown", function (self, button) if (button == "RightButton") then f.EntryBox:ClearFocus() f:Hide() end end)
tinsert (UISpecialFrames, "DetailsFrameworkPrompt")
DF:CreateTitleBar (f, "Prompt!")
DF:ApplyStandardBackdrop (f)
local prompt = f:CreateFontString (nil, "overlay", "GameFontNormal")
prompt:SetPoint ("top", f, "top", 0, -15)
prompt:SetPoint ("top", f, "top", 0, -25)
prompt:SetJustifyH ("center")
prompt:SetSize (360, 36)
f.prompt = prompt
local button_text_template = DF:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE")
local options_dropdown_template = DF:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE")
local button_true = DF:CreateButton (f, nil, 60, 20, "Okey", nil, nil, nil, nil, nil, nil, options_dropdown_template, button_text_template)
button_true:SetPoint ("bottomleft", f, "bottomleft", 10, 5)
f.button_true = button_true
local button_false = DF:CreateButton (f, function() f.textbox:ClearFocus(); f:Hide() end, 60, 20, "Cancel", nil, nil, nil, nil, nil, nil, options_dropdown_template, button_text_template)
button_false:SetPoint ("bottomright", f, "bottomright", -10, 5)
f.button_false = button_false
local textbox = DF:CreateTextEntry (f, function()end, 380, 20, "textbox", nil, nil, options_dropdown_template)
textbox:SetPoint ("topleft", f, "topleft", 10, -45)
textbox:SetPoint ("topleft", f, "topleft", 10, -60)
f.EntryBox = textbox
button_true:SetClickFunction (function()
local button_true = DF:CreateButton (f, nil, 60, 20, "Okey", nil, nil, nil, nil, nil, nil, options_dropdown_template)
button_true:SetPoint ("bottomright", f, "bottomright", -10, 5)
f.button_true = button_true
local button_false = DF:CreateButton (f, function() f.textbox:ClearFocus(); f:Hide() end, 60, 20, "Cancel", nil, nil, nil, nil, nil, nil, options_dropdown_template)
button_false:SetPoint ("bottomleft", f, "bottomleft", 10, 5)
f.button_false = button_false
local executeCallback = function()
local my_func = button_true.true_function
if (my_func) then
local okey, errormessage = pcall (my_func, textbox:GetText())
@@ -2104,6 +2116,14 @@ function DF:ShowTextPromptPanel (message, callback)
end
f:Hide()
end
end
button_true:SetClickFunction (function()
executeCallback()
end)
textbox:SetHook ("OnEnterPressed", function()
executeCallback()
end)
f:Hide()
@@ -2115,7 +2135,6 @@ function DF:ShowTextPromptPanel (message, callback)
DetailsFrameworkPrompt.EntryBox:SetText ("")
DF.text_prompt_panel.prompt:SetText (message)
DF.text_prompt_panel.button_true.true_function = callback
DF.text_prompt_panel.textbox:SetFocus (true)
end
@@ -4853,10 +4872,12 @@ DF.IconRowFunctions = {
iconFrame.Text:Hide()
end
iconFrame:SetSize (self.options.icon_width, self.options.icon_height)
iconFrame:Show()
--> update the size of the frame
self:SetWidth ((self.options.left_padding * 2) + (self.options.icon_padding * (self.NextIcon-2)) + (self.options.icon_width * (self.NextIcon - 1)))
self:SetHeight (self.options.icon_height + (self.options.top_padding * 2))
--> show the frame
self:Show()
@@ -4903,7 +4924,12 @@ DF.IconRowFunctions = {
elseif (side == 13) then
return 1
end
end
end,
OnOptionChanged = function (self, optionName)
self:SetBackdropColor (unpack (self.options.backdrop_color))
self:SetBackdropBorderColor (unpack (self.options.backdrop_border_color))
end,
}
local default_icon_row_options = {
@@ -4912,9 +4938,9 @@ local default_icon_row_options = {
texcoord = {.1, .9, .1, .9},
show_text = true,
text_color = {1, 1, 1, 1},
left_padding = 2, --distance between right and left
top_padding = 2, --distance between top and bottom
icon_padding = 2, --distance between each icon
left_padding = 1, --distance between right and left
top_padding = 1, --distance between top and bottom
icon_padding = 1, --distance between each icon
backdrop = {edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true},
backdrop_color = {0, 0, 0, 0.5},
backdrop_border_color = {0, 0, 0, 1},
+10 -1
View File
@@ -806,7 +806,15 @@ local SwitchOnClick = function (self, button, forced_value, value)
if (slider.return_func) then
value = slider:return_func (value)
end
slider.OnSwitch (slider, slider.FixedValue, value)
--> safe call
local success, errorText = pcall (slider.OnSwitch, slider, slider.FixedValue, value)
if (not success) then
error ("Details! Framework: OnSwitch() " .. (button:GetName() or "-NONAME-") .. " error: " .. (errorText or ""))
end
--> trigger hooks
slider:RunHooksForWidget ("OnSwitch", slider, slider.FixedValue, value)
end
end
@@ -935,6 +943,7 @@ function DF:NewSwitch (parent, container, name, member, w, h, ltext, rtext, defa
h = h or 20
local slider = DF:NewButton (parent, container, name, member, w, h)
slider.HookList.OnSwitch = {}
slider.switch_func = switch_func
slider.return_func = return_func
+181 -9
View File
@@ -4,6 +4,9 @@ if (not DF or not DetailsFrameworkCanLoad) then
return
end
DF_COOLDOWN_RAID = 4
DF_COOLDOWN_EXTERNAL = 3
DF.CooldownsBySpec = {
-- 1 attack cooldown
-- 2 personal defensive cooldown
@@ -107,10 +110,10 @@ DF.CooldownsBySpec = {
--affliction
[265] = {
[205180] = 1, --Summon Darkglare
[113860] = 1, --Dark Soul: Misery
[113860] = 1, --Dark Soul: Misery (talent)
[104773] = 2, --Unending Resolve
[108416] = 2, --Dark Pact
[108416] = 2, --Dark Pact (talent)
[30283] = 5, --Shadowfury
[6789] = 5, --Mortal Coil
@@ -118,11 +121,11 @@ DF.CooldownsBySpec = {
--demo
[266] = {
[265187] = 1, --Summon Demonic Tyrant
[111898] = 1, --Grimoire: Felguard
[267217] = 1, --Nether Portal
[111898] = 1, --Grimoire: Felguard (talent)
[267217] = 1, --Nether Portal (talent)
[104773] = 2, --Unending Resolve
[108416] = 2, --Dark Pact
[108416] = 2, --Dark Pact (talent)
[30283] = 5, --Shadowfury
[6789] = 5, --Mortal Coil
@@ -130,10 +133,10 @@ DF.CooldownsBySpec = {
--destro
[267] = {
[1122] = 1, --Summon Infernal
[113858] = 1, --Dark Soul: Instability
[113858] = 1, --Dark Soul: Instability (talent)
[104773] = 2, --Unending Resolve
[108416] = 2, --Dark Pact
[108416] = 2, --Dark Pact (talent)
[6789] = 5, --Mortal Coil
[30283] = 5, --Shadowfury
@@ -387,12 +390,13 @@ DF.CooldownsBySpec = {
--mistweaver
[270] = {
[122278] = 2, --Dampen Harm (talent)
[198664] = 2, --Invoke Chi-Ji, the Red Crane (talent)
[243435] = 2, --Fortifying Brew
[122783] = 2, --Diffuse Magic (talent)
[116849] = 3, --Life Cocoon
[198664] = 4, --Invoke Chi-Ji, the Red Crane (talent)
[115310] = 4, --Revival
},
@@ -424,6 +428,171 @@ DF.CooldownsBySpec = {
},
}
--> tells the duration, requirements and cooldown of a cooldown
DF.CooldownsInfo = {
--> paladin
[31884] = {cooldown = 120, duration = 20, talent = false, charges = 1, class = "PALADIN", type = 1}, --Avenging Wrath
[216331] = {cooldown = 120, duration = 20, talent = 22190, charges = 1, class = "PALADIN", type = 1}, --Avenging Crusader (talent)
[498] = {cooldown = 60, duration = 8, talent = false, charges = 1, class = "PALADIN", type = 2}, --Divine Protection
[642] = {cooldown = 300, duration = 8, talent = false, charges = 1, class = "PALADIN", type = 2}, --Divine Shield
[105809] = {cooldown = 90, duration = 20, talent = 22164, charges = 1, class = "PALADIN", type = 2}, --Holy Avenger (talent)
[1022] = {cooldown = 300, duration = 10, talent = false, charges = 1, class = "PALADIN", type = 3}, --Blessing of Protection
[633] = {cooldown = 600, duration = false, talent = false, charges = 1, class = "PALADIN", type = 3}, --Lay on Hands
[31821] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "PALADIN", type = 4}, --Aura Mastery
[1044] = {cooldown = 25, duration = 8, talent = false, charges = 1, class = "PALADIN", type = 5}, --Blessing of Freedom
[31850] = {cooldown = 120, duration = 8, talent = false, charges = 1, class = "PALADIN", type = 2}, --Ardent Defender
[86659] = {cooldown = 300, duration = 8, talent = false, charges = 1, class = "PALADIN", type = 2}, --Guardian of Ancient Kings
[204018] = {cooldown = 180, duration = 10, talent = 22435, charges = 1, class = "PALADIN", type = 3}, --Blessing of Spellwarding (talent)
[6940] = {cooldown = 120, duration = 12, talent = false, charges = 1, class = "PALADIN", type = 3}, --Blessing of Sacrifice
[204150] = {cooldown = 180, duration = 6, talent = 23087, charges = 1, class = "PALADIN", type = 4}, --Aegis of Light (talent)
[231895] = {cooldown = 120, duration = 25, talent = 22215, charges = 1, class = "PALADIN", type = 1}, --Crusade (talent)
[184662] = {cooldown = 120, duration = 15, talent = false, charges = 1, class = "PALADIN", type = 2}, --Shield of Vengeance
--> warrior
[107574] = {cooldown = 90, duration = 20, talent = 22397, charges = 1, class = "WARRIOR", type = 1}, --Avatar
[227847] = {cooldown = 90, duration = 5, talent = false, charges = 1, class = "WARRIOR", type = 1}, --Bladestorm
[152277] = {cooldown = 60, duration = 6, talent = 21667, charges = 1, class = "WARRIOR", type = 1}, --Ravager (talent)
[118038] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "WARRIOR", type = 2}, --Die by the Sword
[97462] = {cooldown = 180, duration = 10, talent = false, charges = 1, class = "WARRIOR", type = 4}, --Rallying Cry
[1719] = {cooldown = 90, duration = 10, talent = false, charges = 1, class = "WARRIOR", type = 1}, --Recklessness
[46924] = {cooldown = 60, duration = 4, talent = 22400, charges = 1, class = "WARRIOR", type = 1}, --Bladestorm (talent)
[184364] = {cooldown = 120, duration = 8, talent = false, charges = 1, class = "WARRIOR", type = 2}, --Enraged Regeneration
[228920] = {cooldown = 60, duration = 6, talent = 23099, charges = 1, class = "WARRIOR", type = 1}, --Ravager (talent)
[12975] = {cooldown = 180, duration = 15, talent = false, charges = 1, class = "WARRIOR", type = 2}, --Last Stand
[871] = {cooldown = 8, duration = 240, talent = false, charges = 1, class = "WARRIOR", type = 2}, --Shield Wall
--> warlock
[205180] = {cooldown = 180, duration = 20, talent = false, charges = 1, class = "WARLOCK", type = 1}, --Summon Darkglare
[113860] = {cooldown = 120, duration = 20, talent = 19293, charges = 1, class = "WARLOCK", type = 1}, --Dark Soul: Misery (talent)
[104773] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "WARLOCK", type = 2}, --Unending Resolve
[108416] = {cooldown = 60, duration = 20, talent = 19286, charges = 1, class = "WARLOCK", type = 2}, --Dark Pact (talent)
[265187] = {cooldown = 90, duration = 15, talent = false, charges = 1, class = "WARLOCK", type = 1}, --Summon Demonic Tyrant
[111898] = {cooldown = 120, duration = 15, talent = 21717, charges = 1, class = "WARLOCK", type = 1}, --Grimoire: Felguard
[267217] = {cooldown = 180, duration = 20, talent = 23091, charges = 1, class = "WARLOCK", type = 1}, --Nether Portal
[1122] = {cooldown = 180, duration = 30, talent = false, charges = 1, class = "WARLOCK", type = 1}, --Summon Infernal
[113858] = {cooldown = 120, duration = 20, talent = 23092, charges = 1, class = "WARLOCK", type = 1}, --Dark Soul: Instability (talent)
--> shaman
[198067] = {cooldown = 150, duration = 30, talent = false, charges = 1, class = "SHAMAN", type = 1}, --Fire Elemental
[192249] = {cooldown = 150, duration = 30, talent = 19272, charges = 1, class = "SHAMAN", type = 1}, --Storm Elemental (talent)
[114050] = {cooldown = 180, duration = 15, talent = 21675, charges = 1, class = "SHAMAN", type = 1}, --Ascendance (talent)
[108271] = {cooldown = 90, duration = 8, talent = false, charges = 1, class = "SHAMAN", type = 2}, --Astral Shift
[108281] = {cooldown = 120, duration = 10, talent = 22172, charges = 1, class = "SHAMAN", type = 4}, --Ancestral Guidance (talent)
[51533] = {cooldown = 120, duration = 15, talent = false, charges = 1, class = "SHAMAN", type = 1}, --Feral Spirit
[114051] = {cooldown = 180, duration = 15, talent = 21972, charges = 1, class = "SHAMAN", type = 1}, --Ascendance (talent)
[114052] = {cooldown = 180, duration = 15, talent = 22359, charges = 1, class = "SHAMAN", type = 2}, --Ascendance (talent)
[98008] = {cooldown = 180, duration = 6, talent = false, charges = 1, class = "SHAMAN", type = 4}, --Spirit Link Totem
[108280] = {cooldown = 180, duration = 10, talent = false, charges = 1, class = "SHAMAN", type = 4}, --Healing Tide Totem
[207399] = {cooldown = 240, duration = 30, talent = 22323, charges = 1, class = "SHAMAN", type = 4}, --Ancestral Protection Totem (talent)
--> monk
[115203] = {cooldown = 420, duration = 15, talent = false, charges = 1, class = "MONK", type = 2}, --Fortifying Brew
[115176] = {cooldown = 300, duration = 8, talent = false, charges = 1, class = "MONK", type = 2}, --Zen Meditation
[122278] = {cooldown = 120, duration = 10, talent = 20175, charges = 1, class = "MONK", type = 2}, --Dampen Harm (talent)
[137639] = {cooldown = 90, duration = 15, talent = false, charges = 1, class = "MONK", type = 1}, --Storm, Earth, and Fire
[123904] = {cooldown = 120, duration = 20, talent = 22102, charges = 1, class = "MONK", type = 1}, --Invoke Xuen, the White Tiger (talent)
[152173] = {cooldown = 90, duration = 12, talent = 21191, charges = 1, class = "MONK", type = 1}, --Serenity (talent)
[122470] = {cooldown = 90, duration = 6, talent = false, charges = 1, class = "MONK", type = 2}, --Touch of Karma
[198664] = {cooldown = 180, duration = 25, talent = 22214, charges = 1, class = "MONK", type = 4}, --Invoke Chi-Ji, the Red Crane (talent)
[243435] = {cooldown = 90, duration = 15, talent = false, charges = 1, class = "MONK", type = 2}, --Fortifying Brew
[122783] = {cooldown = 90, duration = 6, talent = 20173, charges = 1, class = "MONK", type = 2}, --Diffuse Magic (talent)
[116849] = {cooldown = 120, duration = 12, talent = false, charges = 1, class = "MONK", type = 3}, --Life Cocoon
[115310] = {cooldown = 180, duration = false, talent = false, charges = 1, class = "MONK", type = 4}, --Revival
--> hunter
[193530] = {cooldown = 120, duration = 20, talent = false, charges = 1, class = "HUNTER", type = 1}, --Aspect of the Wild
[19574] = {cooldown = 90, duration = 12, talent = false, charges = 1, class = "HUNTER", type = 1}, --Bestial Wrath
[201430] = {cooldown = 180, duration = 12, talent = 23044, charges = 1, class = "HUNTER", type = 1}, --Stampede (talent)
[194407] = {cooldown = 90, duration = 20, talent = 22295, charges = 1, class = "HUNTER", type = 1}, --Spitting Cobra (talent)
[193526] = {cooldown = 180, duration = 15, talent = false, charges = 1, class = "HUNTER", type = 1}, --Trueshot
[281195] = {cooldown = 180, duration = 6, talent = false, charges = 1, class = "HUNTER", type = 2}, --Survival of the Fittest
[266779] = {cooldown = 120, duration = 20, talent = false, charges = 1, class = "HUNTER", type = 1}, --Coordinated Assault
[186265] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "HUNTER", type = 2}, --Aspect of the Turtle
[109304] = {cooldown = 120, duration = false, talent = false, charges = 1, class = "HUNTER", type = 2}, --Exhilaration
--> druid
[194223] = {cooldown = 180, duration = 20, talent = false, charges = 1, class = "DRUID", type = 1}, --Celestial Alignment
[102560] = {cooldown = 180, duration = 30, talent = 21702, charges = 1, class = "DRUID", type = 1}, --Incarnation: Chosen of Elune (talent)
[22812] = {cooldown = 60, duration = 12, talent = false, charges = 1, class = "DRUID", type = 2}, --Barkskin
[108238] = {cooldown = 90, duration = false, talent = 18570, charges = 1, class = "DRUID", type = 2}, --Renewal (talent)
[29166] = {cooldown = 180, duration = 12, talent = false, charges = 1, class = "DRUID", type = 3}, --Innervate
[78675] = {cooldown = 60, duration = 8, talent = false, charges = 1, class = "DRUID", type = 5}, --Solar Beam
[106951] = {cooldown = 180, duration = 15, talent = false, charges = 1, class = "DRUID", type = 1}, --Berserk
[102543] = {cooldown = 30, duration = 180, talent = 21704, charges = 1, class = "DRUID", type = 1}, --Incarnation: King of the Jungle (talent)
[61336] = {cooldown = 120, duration = 6, talent = false, charges = 2, class = "DRUID", type = 2}, --Survival Instincts (2min feral 4min guardian, same spellid)
[77764] = {cooldown = 120, duration = 8, talent = false, charges = 1, class = "DRUID", type = 4}, --Stampeding Roar (utility)
[102558] = {cooldown = 180, duration = 30, talent = 22388, charges = 1, class = "DRUID", type = 2}, --Incarnation: Guardian of Ursoc (talent)
[33891] = {cooldown = 180, duration = 30, talent = 22421, charges = 1, class = "DRUID", type = 2}, --Incarnation: Tree of Life (talent)
[102342] = {cooldown = 60, duration = 12, talent = false, charges = 1, class = "DRUID", type = 3}, --Ironbark
[740] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "DRUID", type = 4}, --Tranquility
[197721] = {cooldown = 90, duration = 8, talent = 22404, charges = 1, class = "DRUID", type = 4}, --Flourish (talent)
--> death knight
[275699] = {cooldown = 90, duration = 15, talent = false, charges = 1, class = "DEATHKNIGHT", type = 1}, --Apocalypse
[42650] = {cooldown = 480, duration = 30, talent = false, charges = 1, class = "DEATHKNIGHT", type = 1}, --Army of the Dead
[49206] = {cooldown = 180, duration = 30, talent = 22538, charges = 1, class = "DEATHKNIGHT", type = 1}, --Summon Gargoyle (talent)
[48743] = {cooldown = 120, duration = 15, talent = 23373, charges = 1, class = "DEATHKNIGHT", type = 2}, --Death Pact (talent)
[152279] = {cooldown = 120, duration = 5, talent = 22537, charges = 1, class = "DEATHKNIGHT", type = 1}, --Breath of Sindragosa (talent)
[47568] = {cooldown = 120, duration = 20, talent = false, charges = 1, class = "DEATHKNIGHT", type = 1}, --Empower Rune Weapon
[279302] = {cooldown = 120, duration = 10, talent = 22535, charges = 1, class = "DEATHKNIGHT", type = 1}, --Frostwyrm's Fury (talent)
[49028] = {cooldown = 120, duration = 8, talent = false, charges = 1, class = "DEATHKNIGHT", type = 1}, --Dancing Rune Weapon
[55233] = {cooldown = 90, duration = 10, talent = false, charges = 1, class = "DEATHKNIGHT", type = 2}, --Vampiric Blood
[48792] = {cooldown = 120, duration = 8, talent = false, charges = 1, class = "DEATHKNIGHT", type = 2}, --Icebound Fortitude
[108199] = {cooldown = 120, duration = false, talent = false, charges = 1, class = "DEATHKNIGHT", type = 5}, --Gorefiend's Grasp (utility)
--> demon hunter
[200166] = {cooldown = 240, duration = 30, talent = false, charges = 1, class = "DEMONHUNTER", type = 1}, --Metamorphosis
[206491] = {cooldown = 120, duration = 60, talent = 22547, charges = 1, class = "DEMONHUNTER", type = 1}, --Nemesis (talent)
[196555] = {cooldown = 120, duration = 5, talent = 21865, charges = 1, class = "DEMONHUNTER", type = 2}, --Netherwalk (talent)
[196718] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "DEMONHUNTER", type = 4}, --Darkness
[187827] = {cooldown = 180, duration = 15, talent = false, charges = 1, class = "DEMONHUNTER", type = 2}, --Metamorphosis
--> mage
[12042] = {cooldown = 90, duration = 10, talent = false, charges = 1, class = "MAGE", type = 1}, --Arcane Power
[12051] = {cooldown = 90, duration = 6, talent = false, charges = 1, class = "MAGE", type = 1}, --Evocation
[110960] = {cooldown = 120, duration = 20, talent = false, charges = 1, class = "MAGE", type = 2}, --Greater Invisibility
[190319] = {cooldown = 120, duration = 10, talent = false, charges = 1, class = "MAGE", type = 1}, --Combustion
[55342] = {cooldown = 120, duration = 40, talent = 22445, charges = 1, class = "MAGE", type = 1}, --Mirror Image (talent)
[66] = {cooldown = 300, duration = 20, talent = false, charges = 1, class = "MAGE", type = 2}, --Invisibility
[12472] = {cooldown = 180, duration = 20, talent = false, charges = 1, class = "MAGE", type = 1}, --Icy Veins
[205021] = {cooldown = 78, duration = 5, talent = 22309, charges = 1, class = "MAGE", type = 1}, --Ray of Frost (talent)
[45438] = {cooldown = 240, duration = 10, talent = false, charges = 1, class = "MAGE", type = 2}, --Ice Block
[235219] = {cooldown = 300, duration = false, talent = false, charges = 1, class = "MAGE", type = 5}, --Cold Snap
--> priest
[34433] = {cooldown = 180, duration = 15, talent = false, charges = 1, class = "PRIEST", type = 1}, --Shadowfiend
[123040] = {cooldown = 60, duration = 12, talent = 22094, charges = 1, class = "PRIEST", type = 1}, --Mindbender (talent)
[33206] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "PRIEST", type = 3}, --Pain Suppression
[62618] = {cooldown = 180, duration = 10, talent = false, charges = 1, class = "PRIEST", type = 4}, --Power Word: Barrier
[271466] = {cooldown = 180, duration = 10, talent = 21184, charges = 1, class = "PRIEST", type = 4}, --Luminous Barrier (talent)
[47536] = {cooldown = 90, duration = 10, talent = false, charges = 1, class = "PRIEST", type = 5}, --Rapture
[19236] = {cooldown = 90, duration = 10, talent = false, charges = 1, class = "PRIEST", type = 5}, --Desperate Prayer
[200183] = {cooldown = 120, duration = 20, talent = 21644, charges = 1, class = "PRIEST", type = 2}, --Apotheosis (talent)
[47788] = {cooldown = 180, duration = 10, talent = false, charges = 1, class = "PRIEST", type = 3}, --Guardian Spirit
[64844] = {cooldown = 180, duration = 8, talent = false, charges = 1, class = "PRIEST", type = 4}, --Divine Hymn
[64901] = {cooldown = 300, duration = 6, talent = false, charges = 1, class = "PRIEST", type = 4}, --Symbol of Hope
[265202] = {cooldown = 720, duration = false, talent = 23145, charges = 1, class = "PRIEST", type = 4}, --Holy Word: Salvation (talent)
[8122] = {cooldown = 60, duration = 8, talent = false, charges = 1, class = "PRIEST", type = 5}, --Psychic Scream
[200174] = {cooldown = 60, duration = 15, talent = 21719, charges = 1, class = "PRIEST", type = 1}, --Mindbender (talent)
[193223] = {cooldown = 240, duration = 60, talent = 21979, charges = 1, class = "PRIEST", type = 1}, --Surrender to Madness (talent)
[47585] = {cooldown = 120, duration = 6, talent = false, charges = 1, class = "PRIEST", type = 2}, --Dispersion
[15286] = {cooldown = 120, duration = 15, talent = false, charges = 1, class = "PRIEST", type = 4}, --Vampiric Embrace
--> rogue
[79140] = {cooldown = 120, duration = 20, talent = false, charges = 1, class = "ROGUE", type = 1}, --Vendetta
[1856] = {cooldown = 120, duration = 3, talent = false, charges = 1, class = "ROGUE", type = 2}, --Vanish
[5277] = {cooldown = 120, duration = 10, talent = false, charges = 1, class = "ROGUE", type = 2}, --Evasion
[31224] = {cooldown = 120, duration = 5, talent = false, charges = 1, class = "ROGUE", type = 2}, --Cloak of Shadows
[2094] = {cooldown = 120, duration = 60, talent = false, charges = 1, class = "ROGUE", type = 5}, --Blind
[114018] = {cooldown = 360, duration = 15, talent = false, charges = 1, class = "ROGUE", type = 5}, --Shroud of Concealment
[13750] = {cooldown = 180, duration = 20, talent = false, charges = 1, class = "ROGUE", type = 1}, --Adrenaline Rush
[51690] = {cooldown = 120, duration = 2, talent = 23175, charges = 1, class = "ROGUE", type = 1}, --Killing Spree (talent)
[199754] = {cooldown = 120, duration = 10, talent = false, charges = 1, class = "ROGUE", type = 2}, --Riposte
[121471] = {cooldown = 180, duration = 20, talent = false, charges = 1, class = "ROGUE", type = 1}, --Shadow Blades
}
-- {cooldown = , duration = , talent = false, charges = 1}
DF.CrowdControlSpells = {
[5246] = "WARRIOR", --Intimidating Shout
[132168] = "WARRIOR", --Shockwave (debuff spellid)
@@ -584,7 +753,6 @@ for specId, cooldownTable in pairs (DF.CooldownsBySpec) do
end
function DF:FindClassForCooldown (spellId)
for specId, cooldownTable in pairs (DF.CooldownsBySpec) do
local hasCooldown = cooldownTable [spellId]
@@ -594,3 +762,7 @@ function DF:FindClassForCooldown (spellId)
end
end
function DF:GetCooldownInfo (spellId)
return DF.CooldownsInfo [spellId]
end
+1 -1
View File
@@ -15,6 +15,6 @@
<Script file="LibWindow-1.1\LibWindow-1.1.lua"/>
<Include file="LibCompress\lib.xml"/>
<Include file="LibItemUpgradeInfo-1.0\LibItemUpgradeInfo-1.0.xml"/>
<!-- <Include file="LibGroupInSpecT-1.1\lib.xml"/> -->
<Include file="LibGroupInSpecT-1.1\lib.xml"/>
<Include file="DF\load.xml"/>
</Ui>
+15 -7
View File
File diff suppressed because one or more lines are too long
+4 -2
View File
@@ -574,7 +574,7 @@ end
if (lower == self.meu_id) then
--> os icones dos plugins precisam ser hostiados nessa instancia.
_detalhes.ToolBar:ReorganizeIcons (true) --> no precisa recarregar toda a skin
_detalhes.ToolBar:ReorganizeIcons (true) --> não precisa recarregar toda a skin
end
if (not self.iniciada) then
@@ -1072,7 +1072,9 @@ function _detalhes:agrupar_janelas (lados)
end
end
instancia.break_snap_button:SetAlpha (1)
if (not _detalhes.disable_lock_ungroup_buttons) then
instancia.break_snap_button:SetAlpha (1)
end
if (_detalhes.tutorial.unlock_button < 4) then
+3 -2
View File
@@ -38,7 +38,6 @@ function _detalhes:GetCombatSegments()
return _detalhes.tabela_historico.tabelas
end
------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--> internal
@@ -49,7 +48,9 @@ function historico:NovoHistorico()
end
function historico:adicionar_overall (tabela)
if (tabela:GetCombatTime() <= 10) then
local zoneName, zoneType = GetInstanceInfo()
if (zoneType ~= "none" and tabela:GetCombatTime() <= _detalhes.minimum_overall_combat_time) then
return
end
+18 -4
View File
@@ -734,13 +734,27 @@
local tempo_do_combate = _detalhes.tabela_vigente:GetCombatTime()
local invalid_combat
if ((tempo_do_combate >= _detalhes.minimum_combat_time or not _detalhes.tabela_historico.tabelas[1]) and not _detalhes.tabela_vigente.discard_segment) then
local zoneName, zoneType = GetInstanceInfo()
if (not _detalhes.tabela_vigente.discard_segment and (zoneType == "none" or tempo_do_combate >= _detalhes.minimum_combat_time or not _detalhes.tabela_historico.tabelas[1])) then
_detalhes.tabela_historico:adicionar (_detalhes.tabela_vigente) --move a tabela atual para dentro do histrico
_detalhes:CanSendMissData()
--8.0.1 miss data isn't required at the moment, spells like akari's soul has been removed from the game
--_detalhes:CanSendMissData()
else
invalid_combat = _detalhes.tabela_vigente
--> tutorial about the combat time < then 'minimum_combat_time'
local hasSeenTutorial = _detalhes:GetTutorialCVar ("MIN_COMBAT_TIME")
if (not hasSeenTutorial) then
local lower_instance = _detalhes:GetLowerInstanceNumber()
if (lower_instance) then
lower_instance = _detalhes:GetInstance (lower_instance)
if (lower_instance) then
lower_instance:InstanceAlert ("combat ignored: less than 5 seconds.", {[[Interface\BUTTONS\UI-GROUPLOOT-PASS-DOWN]], 18, 18, false, 0, 1, 0, 1}, 20, {function() Details:Msg ("combat ignored: elapsed time less than 5 seconds."); Details:Msg ("add '|cFFFFFF00Details.minimum_combat_time = 2;|r' on Auto Run Code to change the minimum time.") end})
_detalhes:SetTutorialCVar ("MIN_COMBAT_TIME", true)
end
end
end
--in case of a forced discard segment, just check a second time if we have a previous combat.
if (not _detalhes.tabela_historico.tabelas[1]) then
_detalhes.tabela_vigente = _detalhes.tabela_vigente
@@ -1609,7 +1623,7 @@
if (instancia.rows_showing == 0 and instancia:GetSegment() == -1) then -- -1 overall data
if (not instancia:IsShowingOverallDataWarning()) then
local tutorial = _detalhes:GetTutorialCVar ("OVERALLDATA_WARNING1") or 0
if ((type (tutorial) == "number") and (tutorial < 10)) then
if ((type (tutorial) == "number") and (tutorial < 6)) then
_detalhes:SetTutorialCVar ("OVERALLDATA_WARNING1", tutorial + 1)
instancia:ShowOverallDataWarning (true)
end
+39 -125
View File
@@ -90,10 +90,12 @@
--> ignore deaths
local ignore_death = {}
--> special items
--local soul_capacitor = {} --> trinket from Socrethar the Eternal --WOD only
local paladin_gbom = {} --greater blessing of might
local shaman_slash = {} --storm slash
local shaman_slash_timers = {} --storm slash
local monk_guard_talent = {} --guard talent for bm monks
local source_cache = {} --store the source's guid, name and flag
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
@@ -168,6 +170,7 @@
local SPELLID_SHAMAN_SLASH_DAMAGE = 195256
local SPELLID_PALADIN_GBOM_AURA = 203528
local SPELLID_PALADIN_GBOM_DAMAGE = 205729
local SPELLID_MONK_GUARD = 115295
--> ignore warlock life tap, since it's bugged
local SPELLID_WARLOCK_LIFETAP = 1454
@@ -345,58 +348,11 @@
who_serial = ""
end
--fix for MOTHER Uldir Raid
--> Fix for mage prismatic crystal
--local npcId = _detalhes:GetNpcIdFromGuid (alvo_serial)
--if (npcId == 76933) then
--if (alvo_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-76933%-%w+$")) then --prismatic crystal (mage)
--if (alvo_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-103679%-%w+$")) then --soul effigy (warlock)
-- return
--end
--using pattern, calling API is too slow here
--if (alvo_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-76933%-%w+$")) then
if (alvo_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-103679%-%w+$")) then
return
end
--Erupting Reflection on kiljaeden encounter on ToS
--REMOVE THIS ON 7.3 RELEASE
if (_current_encounter_id == 2051) then --2051 = kiljaeden
--tank add
if (alvo_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-119107%-%w+$")) then
if (_encounter_kiljaeden_wailingreflection_loc == "Wailing Reflection") then
_encounter_kiljaeden_wailingreflection_loc = GetSpellInfo (236378)
end
alvo_name = _encounter_kiljaeden_wailingreflection_loc
elseif (who_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-119107%-%w+$")) then
if (_encounter_kiljaeden_wailingreflection_loc == "Wailing Reflection") then
_encounter_kiljaeden_wailingreflection_loc = GetSpellInfo (236378)
end
who_name = _encounter_kiljaeden_wailingreflection_loc
end
--dps add
if (alvo_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-119206%-%w+$")) then
if (_encounter_kiljaeden_eruptingreflection_loc == "Erupting Reflection") then
_encounter_kiljaeden_eruptingreflection_loc = GetSpellInfo (236710)
end
alvo_name = _encounter_kiljaeden_eruptingreflection_loc
elseif (who_serial:match ("^Creature%-0%-%d+%-%d+%-%d+%-119206%-%w+$")) then
if (_encounter_kiljaeden_eruptingreflection_loc == "Erupting Reflection") then
_encounter_kiljaeden_eruptingreflection_loc = GetSpellInfo (236710)
end
who_name = _encounter_kiljaeden_eruptingreflection_loc
end
end
--> Second try with :find
-- it's 20% faster when comparing Npcs serials, but very slow when comparing other things.
--if (alvo_serial:find ("-76933-")) then
-- return
--end
--> if the parser are allowed to replace spellIDs
if (is_using_spellId_override) then
spellid = override_spellId [spellid] or spellid
@@ -411,7 +367,7 @@
--> spirit link toten
elseif (spellid == 98021) then
return parser:SLT_damage (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spelltype, amount, overkill, school, resisted, blocked, absorbed, critical, glacing, crushing, isoffhand)
--> Light of the Martyr - paladin spell which causes damage to the caster it self
elseif (spellid == 196917) then -- or spellid == 183998 < healing part
local healingActor = healing_cache [who_name]
@@ -426,7 +382,7 @@
elseif (spellid == SPELLID_SHAMAN_SLASH_DAMAGE) then
who_serial, who_name, who_flags = parser:GetRealHitSourceFromBuffOwner (shaman_slash, who_serial, who_name, who_flags, SPELLNAME_SHAMAN_SLASH)
--> Rogue's Akaari's Soul - Soul Rip
--> Rogue's Akaari's Soul - q
elseif (spellid == 220893) then
if (who_flags and _bit_band (who_flags, REACTION_MINE) ~= 0) then
who_serial, who_name, who_flags = UnitGUID ("player"), _detalhes.playername, 0x00000417
@@ -434,7 +390,7 @@
end
end
------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------
--> check if need start an combat
if (not _in_combat) then
@@ -567,14 +523,14 @@
elseif (jogador_alvo.grupo) then --> source = arena enemy or friendly player
--> record avoidance only for tank actors
if (tanks_members_cache [alvo_serial]) then --> autoshot or melee hit
if (tanks_members_cache [alvo_serial]) then
--> monk's stagger
if (jogador_alvo.classe == "MONK") then
if (absorbed) then
--> the absorbed amount was staggered and should not be count as damage taken now
--> this absorbed will hit the player with the stagger debuff
amount = (amount or 0) - absorbed
amount = (amount or 0) - absorbed
end
else
--> advanced damage taken
@@ -831,6 +787,8 @@
function parser:MonkStagger_damage (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spelltype, amount, overkill, school, resisted, blocked, absorbed, critical, glacing, crushing, isoffhand)
--> special behavior for monk stagger debuff periodic damage
--> tag the container to refresh
_current_damage_container.need_refresh = true
@@ -840,12 +798,12 @@
if (not este_jogador) then --> pode ser um desconhecido ou um pet
este_jogador, meu_dono, who_name = _current_damage_container:PegarCombatente (who_serial, who_name, who_flags, true)
if (meu_dono) then --> um pet
if (meu_dono) then --> é um pet
if (who_serial ~= "") then
damage_cache_pets [who_serial] = este_jogador
damage_cache_petsOwners [who_serial] = meu_dono
end
--conferir se o dono j esta no cache
--conferir se o dono já esta no cache
if (not damage_cache [meu_dono.serial] and meu_dono.serial ~= "") then
damage_cache [meu_dono.serial] = meu_dono
end
@@ -858,16 +816,13 @@
damage_cache [who_name] = este_jogador
local _, _, icon = _GetSpellInfo (spellid or 1)
este_jogador.spellicon = icon
--print ("no serial actor", spellname, who_name, "added to cache.")
else
--_detalhes:Msg ("Unknown actor with unknown serial ", spellname, who_name)
end
end
end
end
elseif (meu_dono) then
--> um pet
--> é um pet
who_name = who_name .. " <" .. meu_dono.nome .. ">"
end
@@ -1293,7 +1248,6 @@
function parser:heal_denied (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, alvo_flags2, spellidAbsorb, spellnameAbsorb, spellschoolAbsorb, serialHealer, nameHealer, flagsHealer, flags2Healer, spellidHeal, spellnameHeal, typeHeal, amountDenied)
-- print (who_name, alvo_name, nameHealer, spellidHeal, spellnameHeal, typeHeal, amountDenied)
if (not _in_combat) then
return
end
@@ -1367,51 +1321,7 @@
--return spell:Add (alvo_serial, alvo_name, alvo_flags, cura_efetiva, who_name, absorbed, critical, overhealing)
return spell_heal_func (spell, alvo_serial, alvo_name, alvo_flags, amountDenied, spellidHeal, token, nameHealer, overhealing)
--print ("|token:", token, "|time:", time, "|whoserial:", who_serial, "|whoname:", who_name, "|whoflags:", who_flags, "|alvoserial:", alvo_serial, "|alvoname:", alvo_name, "|alvoflags", alvo_flags, "|alvoflags2:", alvo_flags2, "|spellidAbsorb:", spellidAbsorb, "|spellnameABsorb", spellnameAbsorb, "|spellschoolAbsorb", spellschoolAbsorb, "|serialhealer:", serialHealer, "|nameHealer:", nameHealer, "|flagsHealer:", flagsHealer, "|flagsHealer2:", flags2Healer, "|spellidHeal:", spellidHeal, "|spellnameHeal:", spellnameHeal, "|typeHeal:", typeHeal, "|amountDenied:", amountDenied)
--[[
1 toekn SPELL_HEAL_ABSORBED
2 time 1493837437.157
3 who serial Player-3209-0514A56A
4 who name Bombado
5 who flags 1297
6 alvo serial Player-3209-0514A56A
7 alvo name Bombado
8 alvo flags 1297
9 alvo flags2 0
10 spellid 116888
11 spellname Shroud of Purgatory
12 school 12
13 GUID - Player-3209-0514A56A
14 PLAYERNAME - Bombado
15 FLAGS 1297
16 FLAGS2 0
17 SPELLID 116888
18 SPELLNAME Healing Potion
19 ? 1
20 ? 2677
primeiro actor o quem comandou o absorb
o segundo a vitima seguido da magia que o primeiro actor usou pra o absorb
o terceiro a vitima com a magia que ela usou e foi absorvida
5/3 11:54:58.346 SPELL_HEAL_ABSORBED,
Player-3209-051429E9,"Mephisstoo-Azralon",0x10548,0x0,Player-3209-05144527,"Keyspell-Azralon",0x511,0x0,223929,"Necrotic Wound",0x28,Player-3209-05144527,"Keyspell-Azralon",0x511,0x0,188016,"Ancient Healing Potion",0x1,254466
--heal pot spellID: 28495 - heal 2841
1 SPELL_HEAL_ABSORBED 2 1493837944.856 3 Player-3209-0514A56A 4 Bombado 5 1297 6 Player-3209-0514A56A 7 Bombado 8 1297 9 0 10 116888 11 Shroud of Purgatory 12 32 13 Player-3209-0514A56A 14 Bombado 15 1297 16 0 17 116888 18 Healing Potion 19 1 20 1860 21 nil 22 nil 23 nil 24 nil 25 nil 26 nil 27 nil
1 SPELL_HEAL_ABSORBED 2 1493839447.257 3 Player-3209-0514A56A 4 Bombado 5 1297 6 Player-3209-0514A56A 7 Bombado 8 1297 9 0 10 nil 11 nil 12 nil 13 Player-3209-05DE3E42 14 Yakumile 15 1298 16 0 17 116888 18 Holy Word: Serenity 19 2 20 2690 21 nil 22 nil
1 SPELL_HEAL_ABSORBED 2 1493840761.019 3 Player-3209-0514A56A 4 Bombado 5 1297 6 Player-3209-0514A56A 7 Bombado 8 1297 9 0 10 nil 11 nil 12 nil 13 Player-57-06AB4689 14 Yakumile 15 1298 16 0 17 116888 18 Circle of Healing 19 2 20 673 21 nil 22 nil 23 nil 24 nil 25 nil 26 nil 27 nil
oken: SPELL_HEAL_ABSORBED ime: 1493841853.862 |whoserial: Player-3209-0514A56A |whoname: Bombado |whoflags: 1297 |alvoserial: Player-3209-0514A56A |alvoname: Bombado |alvoflags 1297 |alvoflags2: 0 |spellidAbsorb: 116888 |spellnameABsorb Shroud of Purgatory |spellschoolAbsorb 32 |serialhealer: Player-3209-0514A56A
ameHealer: Bombado |flagsHealer: 1297 |flagsHealer2: 0 |spellidHeal: 116888 |spellnameHeal: Healing Potion ypeHeal: 1 |amountDenied: 870
--]]
end
function parser:heal_absorb (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, alvo_flags2, spellid, spellname, spellschool, owner_serial, owner_name, owner_flags, owner_flags2, shieldid, shieldname, shieldtype, amount)
@@ -1761,9 +1671,6 @@ ameHealer: Bombado |flagsHealer: 1297 |flagsHealer2: 0 |spellidHeal: 116888 |
ignore_death [who_name] = true
return
--elseif (spellid == 184293) then --> WOD trinket: Soul Capacitor T18 (soul eruption 184559) --REMOVE ON LEGION LAUNCH
-- soul_capacitor [who_serial] = _tempo
elseif (spellid == SPELLID_SHAMAN_SLASH_AURA) then --shaman slash
--> handle the buff on parser time
if (shaman_slash_timers [who_serial] and shaman_slash_timers [who_serial] [alvo_serial]) then
@@ -1777,6 +1684,10 @@ ameHealer: Bombado |flagsHealer: 1297 |flagsHealer2: 0 |spellidHeal: 116888 |
--> handle the buff on parser time
parser:Handle3rdPartyBuff (paladin_gbom, who_serial, alvo_serial, true, who_name, who_flags)
elseif (spellid == SPELLID_MONK_GUARD) then
--> BfA monk talent
monk_guard_talent [who_serial] = amount
end
if (_recording_buffs_and_debuffs) then
@@ -2121,7 +2032,7 @@ ameHealer: Bombado |flagsHealer: 1297 |flagsHealer2: 0 |spellidHeal: 116888 |
--> handle shields
if (tipo == "BUFF") then
------------------------------------------------------------------------------------------------
--> buff uptime
if (_recording_buffs_and_debuffs) then
@@ -2134,9 +2045,6 @@ ameHealer: Bombado |flagsHealer: 1297 |flagsHealer2: 0 |spellidHeal: 116888 |
end
end
--if (spellid == 184293) then --> WOD trinket: Soul Capacitor T18 REMOVE ON LEGION LAUNCH
-- soul_capacitor [who_serial] = nil
if (spellid == SPELLID_SHAMAN_SLASH_AURA) then --shaman slash
--as @Kihra from WCL mentioned, slash has a travel time, the hit may land after the buff has gone
local delay_timer = _detalhes:ScheduleTimer ("HandleSlashUnbuff", 2.5, shaman_slash, who_serial, alvo_serial)
@@ -2147,6 +2055,13 @@ ameHealer: Bombado |flagsHealer: 1297 |flagsHealer2: 0 |spellidHeal: 116888 |
elseif (spellid == SPELLID_PALADIN_GBOM_AURA) then --paladin gbom
parser:Handle3rdPartyBuff (paladin_gbom, who_serial, alvo_serial)
elseif (spellid == SPELLID_MONK_GUARD) then
--> BfA monk talent
if (monk_guard_talent [who_serial]) then
local damage_prevented = monk_guard_talent [who_serial] - (amount or 0)
parser:heal (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, alvo_flags2, spellid, spellname, spellschool, damage_prevented, _math_ceil (amount or 0), 0, 0, true)
end
end
------------------------------------------------------------------------------------------------
@@ -2159,22 +2074,13 @@ ameHealer: Bombado |flagsHealer: 1297 |flagsHealer2: 0 |spellidHeal: 116888 |
local overheal = escudo [alvo_name][spellid][who_name]
escudo [alvo_name][spellid][who_name] = 0
if (overheal and overheal > 0) then
--> can't use monk guard since its overheal is computed inside the unbuff
if (overheal and overheal > 0 and spellid ~= SPELLID_MONK_GUARD) then
--> removing the nil at the end before true for is_shield, I have no documentation change about it, not sure the reason why it was addded
return parser:heal (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, alvo_flags2, spellid, spellname, nil, 0, _math_ceil (overheal), 0, 0, true) --0, 0, nil, true
else
return
end
--- pre 6.0
--local escudo_antigo = escudo [alvo_name][spellid][who_name] --> quantidade total do escudo que foi colocado
--local absorb = escudo_antigo - amount
--local overheal = escudo_antigo - absorb
--escudo [alvo_name][spellid][who_name] = nil
--return parser:heal (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, nil, _math_ceil (absorb), _math_ceil (overheal), 0, 0, nil, true) --> ltimo parametro IS_SHIELD
end
escudo [alvo_name][spellid][who_name] = 0
end
@@ -3507,6 +3413,7 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
wipe (source_cache)
wipe (paladin_gbom)
wipe (shaman_slash)
wipe (monk_guard_talent)
end
function parser:Handle3rdPartyBuffs_OnEncounterStart()
@@ -4869,6 +4776,13 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
local role = _UnitGroupRolesAssigned (name)
if (role == "TANK") then
tanks_members_cache [_UnitGUID ("player")] = true
else
local spec = GetSpecialization()
if (spec and spec ~= 0) then
if (GetSpecializationRole (spec) == "TANK") then
tanks_members_cache [_UnitGUID ("player")] = true
end
end
end
end
@@ -4987,7 +4901,7 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
return nil
end
function _detalhes:GetAllActors (_combat, _actorname)
return _detalhes:GetActor (_combat, 1, _actorname), _detalhes:GetActor (_combat, 2, _actorname), _detalhes:GetActor (_combat, 3, _actorname), _detalhes:GetActor (_combat, 4, _actorname)
end
+2 -17
View File
@@ -402,28 +402,13 @@
insets = {left = 1, right = 1, top = 1, bottom = 1}})
options_frame:SetBackdropColor (0, 0, 0, .7)
local texturetitle = options_frame:CreateTexture (nil, "artwork")
texturetitle:SetTexture ([[Interface\CURSOR\Interact]])
texturetitle:SetTexCoord (0, 1, 0, 1)
texturetitle:SetVertexColor (1, 1, 1, 1)
texturetitle:SetPoint ("topleft", options_frame, "topleft", 2, -3)
texturetitle:SetWidth (36)
texturetitle:SetHeight (36)
local title = _detalhes.gump:NewLabel (options_frame, nil, "$parentTitle", nil, title, nil, 20, "yellow")
title:SetPoint ("left", texturetitle, "right", 2, -1)
_detalhes:SetFontOutline (title, true)
Details.gump:ApplyStandardBackdrop (options_frame)
Details.gump:CreateTitleBar (options_frame, title)
local bigdog = _detalhes.gump:NewImage (options_frame, [[Interface\MainMenuBar\UI-MainMenuBar-EndCap-Human]], 110, 120, nil, {1, 0, 0, 1}, "backgroundBigDog", "$parentBackgroundBigDog")
bigdog:SetPoint ("bottomright", options_frame, "bottomright", -3, 0)
bigdog:SetAlpha (.25)
local c = CreateFrame ("Button", nil, options_frame, "UIPanelCloseButton")
c:SetWidth (32)
c:SetHeight (32)
c:SetPoint ("TOPRIGHT", options_frame, "TOPRIGHT", -3, -3)
c:SetFrameLevel (options_frame:GetFrameLevel()+1)
return options_frame
end
end
+7 -1
View File
@@ -581,7 +581,13 @@
local tpe = _type (value)
if (type (key) ~= "string") then
if (type (key) == "function") then
key = "#function#"
elseif (type (key) == "table") then
key = "#table#"
end
if (type (key) ~= "string" and type (key) ~= "number") then
key = "unknown?"
end
+64 -8
View File
@@ -1312,13 +1312,13 @@
GuildRankCheckBox:SetAsCheckBox()
local guild_sync = function()
f.RequestedAmount = 0
f.DownloadedAmount = 0
f.EstimateSize = 0
f.DownloadedSize = 0
f.SyncStartTime = time()
_detalhes.storage:DBGuildSync()
f.GuildSyncButton:Disable()
@@ -2286,6 +2286,9 @@
if (not _G.DetailsClassColorManager) then
gump:CreateSimplePanel (UIParent, 300, 280, Loc ["STRING_OPTIONS_CLASSCOLOR_MODIFY"], "DetailsClassColorManager")
local panel = _G.DetailsClassColorManager
_detalhes.gump:ApplyStandardBackdrop (panel)
local upper_panel = CreateFrame ("frame", nil, panel)
upper_panel:SetAllPoints (panel)
upper_panel:SetFrameLevel (panel:GetFrameLevel()+3)
@@ -2371,8 +2374,9 @@
function _detalhes:OpenBookmarkConfig()
if (not _G.DetailsBookmarkManager) then
gump:CreateSimplePanel (UIParent, 300, 480, Loc ["STRING_OPTIONS_MANAGE_BOOKMARKS"], "DetailsBookmarkManager")
gump:CreateSimplePanel (UIParent, 465, 460, Loc ["STRING_OPTIONS_MANAGE_BOOKMARKS"], "DetailsBookmarkManager")
local panel = _G.DetailsBookmarkManager
_detalhes.gump:ApplyStandardBackdrop (panel)
panel.blocks = {}
local clear_func = function (self, button, id)
@@ -2430,18 +2434,19 @@
else
--par
local o = i-1
clear:SetPoint (150, (( o*10 ) * -1) - 35) --right
clear:SetPoint (250, (( o*10 ) * -1) - 35) --right
end
local set = gump:CreateButton (panel, set_att, 16, 16, nil, i)
set:SetPoint ("left", clear, "right")
set:SetPoint ("right", clear, "right", 110, 0)
set:SetPoint ("right", clear, "right", 180, 0)
set:SetBackdrop (button_backdrop)
set:SetBackdropColor (0, 0, 0, 0.5)
set:SetHook ("OnEnter", set_onenter)
set:SetHook ("OnLeave", set_onleave)
set:InstallCustomTexture (nil, nil, nil, nil, true)
--set:InstallCustomTexture (nil, nil, nil, nil, true)
set:SetTemplate (gump:GetTemplate ("button", "OPTIONS_BUTTON_TEMPLATE"))
local bg_texture = gump:CreateImage (set, [[Interface\AddOns\Details\images\bar_skyline]], 135, 30, "background")
bg_texture:SetAllPoints()
@@ -2453,11 +2458,12 @@
local label = gump:CreateLabel (set, "")
label:SetPoint ("left", icon, "right", 2, 0)
tinsert (panel.blocks, {icon = icon, label = label, bg = set.bg})
tinsert (panel.blocks, {icon = icon, label = label, bg = set.bg, button = set})
end
local normal_coords = {0, 1, 0, 1}
local unknown_coords = {157/512, 206/512, 39/512, 89/512}
function panel:Refresh()
local bookmarks = _detalhes.switch.table
@@ -2486,11 +2492,14 @@
this_block.icon.texcoord = _detalhes.sub_atributos [bookmark.atributo].icones [bookmark.sub_atributo] [2]
this_block.bg:SetVertexColor (.4, .4, .4, .6)
end
this_block.button:SetAlpha (1)
else
this_block.label.text = "-- x -- x --"
this_block.icon.texture = [[Interface\AddOns\Details\images\icons]]
this_block.icon.texcoord = unknown_coords
this_block.bg:SetVertexColor (.4, .1, .1, .12)
this_block.bg:SetVertexColor (.1, .1, .1, .12)
this_block.button:SetAlpha (0.3)
end
end
end
@@ -6533,3 +6542,50 @@ function _detalhes:FormatBackground (f)
f.__background:SetHorizTile (true)
f.__background:SetAllPoints()
end
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--> dump table frame
function Details:DumpTable (t)
return Details:Dump (t)
end
function Details:Dump (t)
if (not DetailsDumpFrame) then
DetailsDumpFrame = DetailsFramework:CreateSimplePanel (UIParent)
DetailsDumpFrame:SetSize (700, 600)
DetailsDumpFrame:SetTitle ("Details! Dump Table [|cFFFF3333Ready Only|r]")
local text_editor = DetailsFramework:NewSpecialLuaEditorEntry (DetailsDumpFrame, 680, 560, "Editbox", "$parentEntry", true)
text_editor:SetPoint ("topleft", DetailsDumpFrame, "topleft", 10, -30)
text_editor.scroll:SetBackdrop (nil)
text_editor.editbox:SetBackdrop (nil)
text_editor:SetBackdrop (nil)
DetailsFramework:ReskinSlider (text_editor.scroll)
if (not text_editor.__background) then
text_editor.__background = text_editor:CreateTexture (nil, "background")
end
text_editor:SetBackdrop ({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1})
text_editor:SetBackdropBorderColor (0, 0, 0, 1)
text_editor.__background:SetColorTexture (0.2317647, 0.2317647, 0.2317647)
text_editor.__background:SetVertexColor (0.27, 0.27, 0.27)
text_editor.__background:SetAlpha (0.8)
text_editor.__background:SetVertTile (true)
text_editor.__background:SetHorizTile (true)
text_editor.__background:SetAllPoints()
end
t = t or {}
local s = Details.table.dump (t)
DetailsDumpFrame.Editbox:SetText (s)
DetailsDumpFrame:Show()
end
+1 -1
View File
@@ -730,7 +730,7 @@ local PixelFrameOnEnter = function (self)
local onlyName = _detalhes:GetOnlyName (playerName)
GameCooltip2:AddLine (onlyName)
local classIcon, L, R, B, T = _detalhes:GetClassIcon (mythicDungeonCharts.ChartTable.Players [playerName].Class)
local classIcon, L, R, B, T = _detalhes:GetClassIcon (mythicDungeonCharts.ChartTable.Players [playerName] and mythicDungeonCharts.ChartTable.Players [playerName].Class)
GameCooltip2:AddIcon (classIcon, 1, 1, 16, 16, L, R, B, T)
GameCooltip2:AddLine (Details:GetCurrentToKFunction()(nil, floor (dps)))
+2 -1
View File
@@ -1016,7 +1016,8 @@ local default_profile = {
cloud_capture = true,
--> combat
minimum_combat_time = 5,
minimum_combat_time = 5, --combats with less then this in elapsed time is discarted
minimum_overall_combat_time = 10, --minimum time the combat must have to be added into the overall data
overall_flag = 0x10,
overall_clear_newboss = true,
overall_clear_newchallenge = true,
+100 -2
View File
@@ -2,6 +2,105 @@
--> install data for raiding tiers
do
--> data for Uldir (BFA tier 1)
-- UldirRaid_BossFaces.tga
-- UldirRaid_Icon256x128.tga
local INSTANCE_EJID = 1031
local INSTANCE_MAPID = 1148
local HDIMAGESPATH = "Details\\images\\raid"
local HDFILEPREFIX = "UldirRaid"
local LOADINGSCREEN_FILE, LOADINGSCREEN_COORDS = "Loadingscreen_NazmirRaid", {0, 1, 285/1024, 875/1024}
local EJ_LOREBG = "UI-EJ-LOREBG-Uldir"
local PORTRAIT_LIST = {
2176749, --Taloc - Taloc
2176741, --MOTHER - MOTHER
2176725, --Fetid Devourer - Fetid Devourer
2176761, --Zek'voz - Zek'voz, Herald of N'zoth
2176757, --Vectis - Vectis
2176762, --Zul - Zul, Reborn
2176742, --Mythrax the Unraveler - Mythrax the Unraveler
2176728, --G'huun - G'huun
}
local ENCOUNTER_ID_CL = {
2144, 2141, 2128, 2136, 2134, 2145, 2135, 2122,
[2144] = 1, --Taloc - Taloc
[2141] = 2, --MOTHER - MOTHER
[2128] = 3, --Fetid Devourer - Fetid Devourer
[2136] = 4, --Zek'voz - Zek'voz, Herald of N'zoth
[2134] = 5, --Vectis - Vectis
[2145] = 6, --Zul - Zul, Reborn
[2135] = 7, --Mythrax the Unraveler - Mythrax the Unraveler
[2122] = 8, --G'huun - G'huun
}
local ENCOUNTER_ID_EJ = {
2168, 2167, 2146, 2169, 2166, 2195, 2194, 2147,
[2168] = 1, --Taloc
[2167] = 2, --MOTHER
[2146] = 3, --Fetid Devourer
[2169] = 4, --Zek'voz, Herald of N'zoth
[2166] = 5, --Vectis
[2195] = 6, --Zul, Reborn
[2194] = 7, --Mythrax the Unraveler
[2147] = 8, --G'huun
}
--> install the raid
C_Timer.After (10, function()
--load encounter journal
EJ_SelectInstance (INSTANCE_EJID)
local InstanceName = EJ_GetInstanceInfo (INSTANCE_EJID)
--build the boss name list
local BOSSNAMES = {}
local ENCOUNTERS = {}
for i = 1, #PORTRAIT_LIST do
local bossName = EJ_GetEncounterInfoByIndex (i, INSTANCE_EJID)
if (bossName) then
tinsert (BOSSNAMES, bossName)
local encounterTable = {
boss = bossName,
--portrait = "Interface\\EncounterJournal\\" .. PORTRAIT_LIST [i],
portrait = PORTRAIT_LIST [i],
}
tinsert (ENCOUNTERS, encounterTable)
else
break
end
end
_detalhes:InstallEncounter ({
id = INSTANCE_MAPID, --map id
ej_id = INSTANCE_EJID, --encounter journal id
name = InstanceName,
icons = "Interface\\AddOns\\" .. HDIMAGESPATH .. "\\" .. HDFILEPREFIX .. "_BossFaces",
icon = "Interface\\AddOns\\" .. HDIMAGESPATH .. "\\" .. HDFILEPREFIX .. "_Icon256x128",
is_raid = true,
backgroundFile = {file = "Interface\\Glues\\LOADINGSCREENS\\" .. LOADINGSCREEN_FILE, coords = LOADINGSCREEN_COORDS},
backgroundEJ = "Interface\\EncounterJournal\\" .. EJ_LOREBG,
encounter_ids = ENCOUNTER_ID_EJ,
encounter_ids2 = ENCOUNTER_ID_CL,
boss_names = BOSSNAMES,
encounters = ENCOUNTERS,
boss_ids = {
--npc ids
},
})
end)
end
do
--> data for Antorus, the Burning Throne raid
@@ -111,5 +210,4 @@ do
Details:ScheduleTimer ("ScheduleInstallRaidDataForAntorus", 2)
end
end
+5 -1
View File
@@ -25,7 +25,7 @@ function SlashCmdList.DETAILS (msg, editbox)
elseif (command == Loc ["STRING_SLASH_NEW"] or command == "new") then
_detalhes:CriarInstancia (nil, true)
elseif (command == Loc ["STRING_SLASH_HISTORY"] or command == "history" or command == "score" or command == "rank" or command == "ranking" or command == "statistics") then
elseif (command == Loc ["STRING_SLASH_HISTORY"] or command == "history" or command == "score" or command == "rank" or command == "ranking" or command == "statistics" or command == "stats") then
_detalhes:OpenRaidHistoryWindow()
elseif (command == Loc ["STRING_SLASH_TOGGLE"] or command == "toggle") then
@@ -162,6 +162,10 @@ function SlashCmdList.DETAILS (msg, editbox)
elseif (command == Loc ["STRING_SLASH_CHANGES"] or command == Loc ["STRING_SLASH_CHANGES_ALIAS1"] or command == Loc ["STRING_SLASH_CHANGES_ALIAS2"] or command == "news" or command == "updates") then
_detalhes:OpenNewsWindow()
elseif (command == "spells") then
Details.OpenForge()
DetailsForgePanel.SelectModule (_, _, 2)
elseif (command == "feedback") then
_detalhes.OpenFeedbackWindow()
+10 -15
View File
@@ -55,9 +55,6 @@ do
end
end
--[1] = {name = Loc ["STRING_MELEE"], icon = [[Interface\AddOns\Details\images\melee.tga]]},
--[2] = {name = Loc ["STRING_AUTOSHOT"], icon = [[Interface\AddOns\Details\images\autoshot.tga]]},
local default_user_spells = {
[1] = {name = Loc ["STRING_MELEE"], icon = [[Interface\ICONS\INV_Sword_04]]},
[2] = {name = Loc ["STRING_AUTOSHOT"], icon = [[Interface\ICONS\INV_Weapon_Bow_07]]},
@@ -71,27 +68,25 @@ do
[98021] = {name = Loc ["STRING_SPIRIT_LINK_TOTEM"]},
[44461] = {name = GetSpellInfo (44461) .. " (" .. Loc ["STRING_EXPLOSION"] .. ")"}, --> Living Bomb (explosion)
[161576] = {name = GetSpellInfo (161576) .. " (" .. Loc ["STRING_EXPLOSION"] .. ")"}, --> Ko'ragh's Overflowing Energy (explosion)
[161612] = {name = GetSpellInfo (161576) .. " (" .. Loc ["STRING_CAUGHT"] .. ")"}, --> Ko'ragh's Overflowing Energy (caught)
[158336] = {name = GetSpellInfo (158336) .. " (" .. Loc ["STRING_WAVE"] .. " #1)"}, --> Twins Ogron Pulverize waves.
[158417] = {name = GetSpellInfo (158417) .. " (" .. Loc ["STRING_WAVE"] .. " #2)"}, --> Twins Ogron Pulverize waves.
[158420] = {name = GetSpellInfo (158420) .. " (" .. Loc ["STRING_WAVE"] .. " #3)"}, --> Twins Ogron Pulverize waves.
[59638] = {name = GetSpellInfo (59638) .. " (" .. Loc ["STRING_MIRROR_IMAGE"] .. ")"}, --> Mirror Image's Frost Bolt (mage)
[88082] = {name = GetSpellInfo (88082) .. " (" .. Loc ["STRING_MIRROR_IMAGE"] .. ")"}, --> Mirror Image's Fireball (mage)
[94472] = {name = GetSpellInfo (94472) .. " (" .. Loc ["STRING_CRITICAL_ONLY"] .. ")"}, --> Atonement critical hit (priest)
[33778] = {name = GetSpellInfo (33778) .. " (bloom)"}, --lifebloom (bloom)
[33778] = {name = GetSpellInfo (33778) .. " (Bloom)"}, --lifebloom (bloom)
[121414] = {name = GetSpellInfo (121414) .. " (Glaive #1)"}, --> glaive toss (hunter)
[120761] = {name = GetSpellInfo (120761) .. " (Glaive #2)"}, --> glaive toss (hunter)
[213786] = {name = GetSpellInfo (213786) .. " (trinket)"},
[214350] = {name = GetSpellInfo (214350) .. " (trinket)"},
[224078] = {name = GetSpellInfo (224078) .. " (trinket)"},
[212739] = {name = GetSpellInfo (212739) .. " (Main Target)"}, --DK Epidemic
[215969] = {name = GetSpellInfo (215969) .. " (AoE)"}, --DK Epidemic
[70890] = {name = GetSpellInfo (70890) .. " (Shadow)"}, --DK Scourge Strike
[55090] = {name = GetSpellInfo (55090) .. " (Physical)"}, --DK Scourge Strike
[49184] = {name = GetSpellInfo (49184) .. " (Main Target)"}, --DK Howling Blast
[237680] = {name = GetSpellInfo (237680) .. " (AoE)"}, --DK Howling Blast
}
+1 -1
View File
@@ -489,7 +489,7 @@ function gump:NewTextBox (parent, container, member, func, param1, param2, w, h,
return editbox
end
function gump:NewScrollBar (master, slave, x, y)
function gump:NewScrollBar2 (master, slave, x, y)
local slider_gump = CreateFrame ("Slider", master:GetName() and master:GetName() .. "SliderGump" or "DetailsSliderGump" .. math.random (1, 10000000), master)
slider_gump.scrollMax = 560 --default - tamanho da janela de fundo
+1 -1
View File
@@ -5349,7 +5349,7 @@ local target_on_enter = function (self)
if (barra.show and type (barra.show) == "number") then
local actor = barra.other_actor or info.jogador
local spell = actor.spells:PegaHabilidade (barra.show)
local spell = actor.spells and actor.spells:PegaHabilidade (barra.show)
if (spell) then
local ActorTargetsSortTable = {}
+1 -3
View File
@@ -4,9 +4,7 @@ local Loc = LibStub ("AceLocale-3.0"):GetLocale ( "Details" )
local g = _detalhes.gump
local _
function _detalhes:DumpTable (text_to_show, dumpvalues, keeptext)
return _detalhes:OpenNewsWindow (text_to_show, true, keeptext)
end
function _detalhes:OpenNewsWindow (text_to_show, dumpvalues, keeptext)
+1 -1
View File
@@ -4366,7 +4366,7 @@ function window:CreateFrame1()
--lock unlock
g:NewButton (frame1, _, "$parentLockButton", "LockButton", window.buttons_width, window.buttons_height, _detalhes.lock_instance_function, nil, nil, nil, Loc ["STRING_OPTIONS_WC_LOCK"], 1, options_button_template)
g:NewButton (frame1, _, "$parentLockButton", "LockButton", window.buttons_width, window.buttons_height, _detalhes.lock_instance_function, true, true, nil, Loc ["STRING_OPTIONS_WC_LOCK"], 1, options_button_template)
--frame1.LockButton:InstallCustomTexture (nil, nil, nil, nil, nil, true)
window:CreateLineBackground2 (frame1, "LockButton", "LockButton", Loc ["STRING_OPTIONS_WC_LOCK_DESC"], nil, {1, 0.8, 0}, button_color_rgb)
+54 -17
View File
@@ -1733,9 +1733,10 @@ function _detalhes:RefreshLockedState()
return true
end
local lockFunctionOnClick = function (button, button_type, button2)
local lockFunctionOnClick = function (button, button_type, button2, isFromOptionsButton)
if (_detalhes.disable_lock_ungroup_buttons) then
--isFromOptionsButton is true when the call if from the button in the display section of the options panel
if (_detalhes.disable_lock_ungroup_buttons and isFromOptionsButton ~= true) then
return
end
@@ -1749,8 +1750,12 @@ local lockFunctionOnClick = function (button, button_type, button2)
baseframe.instance.isLocked = false
button.label:SetText (Loc ["STRING_LOCK_WINDOW"])
button:SetWidth (button.label:GetStringWidth()+2)
baseframe.resize_direita:SetAlpha (1)
baseframe.resize_esquerda:SetAlpha (1)
if (not _detalhes.disable_lock_ungroup_buttons) then
baseframe.resize_direita:SetAlpha (1)
baseframe.resize_esquerda:SetAlpha (1)
end
button:ClearAllPoints()
button:SetPoint ("right", baseframe.resize_direita, "left", -1, 1.5)
else
@@ -5071,7 +5076,6 @@ function _detalhes:InstanceButtonsColors (red, green, blue, alpha, no_save, only
if (self:IsLowerInstance()) then
for _, ThisButton in _ipairs (_detalhes.ToolBar.Shown) do
ThisButton:SetAlpha (alpha)
--print (ThisButton:GetName())
end
end
@@ -5671,6 +5675,13 @@ function _detalhes:ToolbarMenuSetButtons (_mode, _segment, _attributes, _report,
total_buttons_shown = total_buttons_shown + 1
end
end
if (self.baseframe.cabecalho.PluginIconsSeparator:IsShown()) then
if (self.baseframe.cabecalho.modo_selecao:GetAlpha() == 0) then
self.baseframe.cabecalho.PluginIconsSeparator:Hide()
end
end
end
self.total_buttons_shown = total_buttons_shown
@@ -7447,28 +7458,40 @@ function _detalhes:SetBackdropTexture (texturename)
end
-- ~alpha (transparency of buttons on the toolbar)
-- ~alpha (transparency of buttons on the toolbar) ~autohide ãutohide ~menuauto
function _detalhes:SetAutoHideMenu (left, right, interacting)
--30/07/2018: the separation by left and right menu icons doesn't exists for years, but it was still active in the code making
--the toolbar icons show on initialization even when the options to auto hide them enabled.
--the code to set the alpha was already updated to only one anhor (left) but this function was still calling to update the right anchor (deprecated)
if (interacting) then
if (self.is_interacting) then
if (self.auto_hide_menu.left) then
local r, g, b = unpack (self.color_buttons)
self:InstanceButtonsColors (r, g, b, 1, true, true) --no save, only left
if (self.baseframe.cabecalho.PluginIconsSeparator) then
self.baseframe.cabecalho.PluginIconsSeparator:Show()
end
end
if (self.auto_hide_menu.right) then
local r, g, b = unpack (self.color_buttons)
self:InstanceButtonsColors (r, g, b, 1, true, nil, true) --no save, only right
end
-- if (self.auto_hide_menu.right) then
-- local r, g, b = unpack (self.color_buttons)
-- self:InstanceButtonsColors (r, g, b, 1, true, nil, true) --no save, only right
-- end
else
if (self.auto_hide_menu.left) then
local r, g, b = unpack (self.color_buttons)
self:InstanceButtonsColors (r, g, b, 0, true, true) --no save, only left
if (self.baseframe.cabecalho.PluginIconsSeparator) then
self.baseframe.cabecalho.PluginIconsSeparator:Hide()
end
end
if (self.auto_hide_menu.right) then
local r, g, b = unpack (self.color_buttons)
self:InstanceButtonsColors (r, g, b, 0, true, nil, true) --no save, only right
end
-- if (self.auto_hide_menu.right) then
-- local r, g, b = unpack (self.color_buttons)
-- self:InstanceButtonsColors (r, g, b, 0, true, nil, true) --no save, only right
-- end
end
return
end
@@ -7484,18 +7507,31 @@ function _detalhes:SetAutoHideMenu (left, right, interacting)
self.auto_hide_menu.right = right
local r, g, b = unpack (self.color_buttons)
if (not left) then
--auto hide is off
self:InstanceButtonsColors (r, g, b, 1, true, true) --no save, only left
if (self.baseframe.cabecalho.PluginIconsSeparator) then
self.baseframe.cabecalho.PluginIconsSeparator:Show()
end
else
if (self.is_interacting) then
self:InstanceButtonsColors (r, g, b, 1, true, true) --no save, only left
if (self.baseframe.cabecalho.PluginIconsSeparator) then
self.baseframe.cabecalho.PluginIconsSeparator:Show()
end
else
self:InstanceButtonsColors (0, 0, 0, 0, true, true) --no save, only left
if (self.baseframe.cabecalho.PluginIconsSeparator) then
self.baseframe.cabecalho.PluginIconsSeparator:Hide()
end
end
end
--[=[
if (not right) then
--auto hide is off
self:InstanceButtonsColors (r, g, b, 1, true, nil, true) --no save, only right
@@ -7506,7 +7542,8 @@ function _detalhes:SetAutoHideMenu (left, right, interacting)
self:InstanceButtonsColors (0, 0, 0, 0, true, nil, true) --no save, only right
end
end
--]=]
self:RefreshAttributeTextSize()
--auto_hide_menu = {left = false, right = false},
Binary file not shown.
Binary file not shown.
@@ -1,93 +0,0 @@
do
local INSTANCE_EJID = 768
local INSTANCE_MAPID = 1520
local HDPATH = "Details_RaidInfo-EmeraldNightmare"
local LOADINGSCREEN_FILE, LOADINGSCREEN_COORDS = "LoadScreen_EmeraldNightmareRaid_wide", {0, 1, 228/1024, 874/1024}
local EJ_LOREBG = "UI-EJ-LOREBG-TheEmeraldNightmare"
local PORTRAIT_LIST = {
"UI-EJ-BOSS-Nythendra",
"UI-EJ-BOSS-Elerethe Renferal",
"UI-EJ-BOSS-Ilgynoth Heart of Corruption",
"UI-EJ-BOSS-Ursoc",
"UI-EJ-BOSS-Dragons of Nightmare",
"UI-EJ-BOSS-Cenarius",
"UI-EJ-BOSS-Xavius",
}
local ENCOUNTER_ID_CL = {
[1853] = 1, --Nythendra
[1876] = 2, --Elerethe Renferal
[1873] = 3, --Il'gynoth, Heart of Corruption
[1841] = 4, --Ursoc
[1854] = 5, --Dragons of Nightmare
[1877] = 6, --Cenarius
[1864] = 7, --Xavius
}
local ENCOUNTER_ID_EJ = {
1703, 1744, 1738, 1667, 1704, 1750, 1726,
[1703] = 1, --Nythendra
[1744] = 2, --Elerethe Renferal
[1738] = 3, --Il'gynoth, Heart of Corruption
[1667] = 4, --Ursoc
[1704] = 5, --Dragons of Nightmare
[1750] = 6, --Cenarius
[1726] = 7, --Xavius
}
function Details:InstallEmeraldNightmareEncounter()
--load encounter journal
EJ_SelectInstance (INSTANCE_EJID)
local InstanceName = EJ_GetInstanceInfo (INSTANCE_EJID)
--build the boss names list
local BOSSNAMES = {}
local ENCOUNTERS = {}
for i = 1, #PORTRAIT_LIST do
local bossName = EJ_GetEncounterInfoByIndex (i, INSTANCE_EJID)
if (bossName) then
tinsert (BOSSNAMES, bossName)
local encounterTable = {
boss = bossName,
portrait = "Interface\\EncounterJournal\\" .. PORTRAIT_LIST [i],
}
tinsert (ENCOUNTERS, encounterTable)
else
break
end
end
_detalhes:InstallEncounter ({
id = INSTANCE_MAPID, --map id
ej_id = INSTANCE_EJID, --encounter journal id
name = InstanceName,
icons = "Interface\\AddOns\\" .. HDPATH .. "\\boss_faces",
icon = "Interface\\AddOns\\" .. HDPATH .. "\\icon256x128",
is_raid = true,
backgroundFile = {file = "Interface\\Glues\\LOADINGSCREENS\\" .. LOADINGSCREEN_FILE, coords = LOADINGSCREEN_COORDS},
backgroundEJ = "Interface\\EncounterJournal\\" .. EJ_LOREBG,
encounter_ids = ENCOUNTER_ID_EJ,
encounter_ids2 = ENCOUNTER_ID_CL,
boss_names = BOSSNAMES,
encounters = ENCOUNTERS,
boss_ids = { --npc ids
},
})
--remove the install from the memory
Details.InstallEmeraldNightmareEncounter = nil
end
--install the encounter
Details:ScheduleTimer ("InstallEmeraldNightmareEncounter", 2)
end
@@ -1,6 +0,0 @@
## Interface: 70300
## Title: Details: Emerald Nightmare
## Notes: Plugin for Details
## RequiredDeps: Details
Details_RaidInfo-EmeraldNightmare.lua
@@ -1,102 +0,0 @@
do
local INSTANCE_EJID = 786
local INSTANCE_MAPID = 1530--?
local HDPATH = "Details_RaidInfo-Nighthold"
local LOADINGSCREEN_FILE, LOADINGSCREEN_COORDS = "LoadScreen_SuramarRaid", {0, 1, 282/1024, 872/1024}
local EJ_LOREBG = "UI-EJ-LOREBG-TheNighthold"
local PORTRAIT_LIST = {
"UI-EJ-BOSS-Skorpyron",
"UI-EJ-BOSS-Chronomatic Anomaly",
"UI-EJ-BOSS-Trilliax",
"UI-EJ-BOSS-Spellblade Aluriel",
"UI-EJ-BOSS-Tichondrius",
"UI-EJ-BOSS-Krosus",
"UI-EJ-BOSS-Botanist",
"UI-EJ-BOSS-Star Augur Etraeus",
"UI-EJ-BOSS-Grand Magistrix Elisande",
"UI-EJ-BOSS-Guldan",
}
local ENCOUNTER_ID_CL = {
[1849] = 1, --Skorpyron
[1865] = 2, --Chronomatic Anomaly
[1867] = 3, --Trilliax
[1871] = 4, --Spellblade Aluriel
[1862] = 5, --Tichondrius
[1842] = 6, --Krosus
[1886] = 7, --High Botanist Tel'arn
[1863] = 8, --Star Augur Etraeus
[1872] = 9, --Grand Magistrix Elisande
[1866] = 10, --Gul'dan
}
local ENCOUNTER_ID_EJ = {
1706, 1725, 1731, 1751, 1762, 1713, 1761, 1732, 1743, 1737,
[1706] = 1, --Skorpyron
[1725] = 2, --Chronomatic Anomaly
[1731] = 3, --Trilliax
[1751] = 4, --Spellblade Aluriel
[1762] = 5, --Tichondrius
[1713] = 6, --Krosus
[1761] = 7, --High Botanist Tel'arn
[1732] = 8, --Star Augur Etraeus
[1743] = 9, --Grand Magistrix Elisande
[1737] = 10, --Gul'dan
}
function Details:InstallNightholdEncounter()
--load encounter journal
EJ_SelectInstance (INSTANCE_EJID)
local InstanceName = EJ_GetInstanceInfo (INSTANCE_EJID)
--build the boss names list
local BOSSNAMES = {}
local ENCOUNTERS = {}
for i = 1, #PORTRAIT_LIST do
local bossName = EJ_GetEncounterInfoByIndex (i, INSTANCE_EJID)
if (bossName) then
tinsert (BOSSNAMES, bossName)
local encounterTable = {
boss = bossName,
portrait = "Interface\\EncounterJournal\\" .. PORTRAIT_LIST [i],
}
tinsert (ENCOUNTERS, encounterTable)
else
break
end
end
_detalhes:InstallEncounter ({
id = INSTANCE_MAPID, --map id
ej_id = INSTANCE_EJID, --encounter journal id
name = InstanceName,
icons = "Interface\\AddOns\\" .. HDPATH .. "\\boss_faces",
icon = "Interface\\AddOns\\" .. HDPATH .. "\\icon256x128",
is_raid = true,
backgroundFile = {file = "Interface\\Glues\\LOADINGSCREENS\\" .. LOADINGSCREEN_FILE, coords = LOADINGSCREEN_COORDS},
backgroundEJ = "Interface\\EncounterJournal\\" .. EJ_LOREBG,
encounter_ids = ENCOUNTER_ID_EJ,
encounter_ids2 = ENCOUNTER_ID_CL,
boss_names = BOSSNAMES,
encounters = ENCOUNTERS,
boss_ids = { --npc ids
},
})
--remove the install from the memory
Details.InstallNightholdEncounter = nil
end
--install the encounter
Details:ScheduleTimer ("InstallNightholdEncounter", 2)
end
@@ -1,6 +0,0 @@
## Interface: 70300
## Title: Details: Nighthold
## Notes: Plugin for Details
## RequiredDeps: Details
Details_RaidInfo-Nighthold.lua
Binary file not shown.
Binary file not shown.
@@ -1,100 +0,0 @@
do
local INSTANCE_EJID = 875
local INSTANCE_MAPID = 1676
local HDPATH = "Details_RaidInfo-TombOfSargeras"
local LOADINGSCREEN_FILE, LOADINGSCREEN_COORDS = "LoadScreen_TombOfSargerasRAID_wide", {0, 1, 285/1024, 875/1024}
local EJ_LOREBG = "UI-EJ-LOREBG-TombOfSargeras"
local PORTRAIT_LIST = {
"UI-EJ-BOSS-Goroth", --1579934, --Goroth - Goroth
"UI-EJ-BOSS-Inquisition", --1579936, --Atrigan - Demonic Inquisition
"UI-EJ-BOSS-NagaBrute", --1579940, --Harjatan - Harjatan
"UI-EJ-BOSS-HuntressKasparian", --1579935, --Huntress Kasparian - Sisters of the Moon
"UI-EJ-BOSS-MistressSasszine", --1579939, --Mistress Sassz'ine - Mistress Sassz'ine
"UI-EJ-BOSS-Veliskarr", --1579943, --Engine of Souls - The Desolate Host
"UI-EJ-BOSS-FelTitan", --1579933, --Maiden of Vigilance - Maiden of Vigilance
"UI-EJ-BOSS-FallenAvatar", --1579932, --Fallen Avatar - Fallen Avatar
"UI-EJ-BOSS-KiljaedenLegion", --1385746, --Kil'jaeden - Kil'jaeden
}
local ENCOUNTER_ID_CL = {
2032, 2048, 2036, 2050, 2037, 2054, 2052, 2038, 2051,
[2032] = 1, --Goroth
[2048] = 2, --Demonic Inquisition
[2036] = 3, --Harjatan
[2050] = 4, --Sisters of the Moon
[2037] = 5, --Mistress Sassz'ine
[2054] = 6, --The Desolate Host
[2052] = 7, --Maiden of Vigilance
[2038] = 8, --Fallen Avatar
[2051] = 9, --Kil'jaeden
}
local ENCOUNTER_ID_EJ = {
1862, 1867, 1856, 1903, 1861, 1896, 1897, 1873, 1898,
[1862] = 1, --Goroth
[1867] = 2, --Demonic Inquisition
[1856] = 3, --Harjatan
[1903] = 4, --Sisters of the Moon
[1861] = 5, --Mistress Sassz'ine
[1896] = 6, --The Desolate Host
[1897] = 7, --Maiden of Vigilance
[1873] = 8, --Fallen Avatar
[1898] = 9, --Kil'jaeden
}
function Details:InstallTombOfSargerasEncounter()
--load encounter journal
EJ_SelectInstance (INSTANCE_EJID)
local InstanceName = EJ_GetInstanceInfo (INSTANCE_EJID)
--build the boss names list
local BOSSNAMES = {}
local ENCOUNTERS = {}
for i = 1, #PORTRAIT_LIST do
local bossName = EJ_GetEncounterInfoByIndex (i, INSTANCE_EJID)
if (bossName) then
tinsert (BOSSNAMES, bossName)
local encounterTable = {
boss = bossName,
portrait = "Interface\\EncounterJournal\\" .. PORTRAIT_LIST [i],
}
tinsert (ENCOUNTERS, encounterTable)
else
break
end
end
_detalhes:InstallEncounter ({
id = INSTANCE_MAPID, --map id
ej_id = INSTANCE_EJID, --encounter journal id
name = InstanceName,
icons = "Interface\\AddOns\\" .. HDPATH .. "\\boss_faces",
icon = "Interface\\AddOns\\" .. HDPATH .. "\\icon256x128",
is_raid = true,
backgroundFile = {file = "Interface\\Glues\\LOADINGSCREENS\\" .. LOADINGSCREEN_FILE, coords = LOADINGSCREEN_COORDS},
backgroundEJ = "Interface\\EncounterJournal\\" .. EJ_LOREBG,
encounter_ids = ENCOUNTER_ID_EJ,
encounter_ids2 = ENCOUNTER_ID_CL,
boss_names = BOSSNAMES,
encounters = ENCOUNTERS,
boss_ids = { --npc ids
},
})
--remove the install from the memory
Details.InstallTombOfSargerasEncounter = nil
end
--install the encounter
Details:ScheduleTimer ("InstallTombOfSargerasEncounter", 2)
end
@@ -1,6 +0,0 @@
## Interface: 70300
## Title: Details: Tomb of Sargeras
## Notes: Plugin for Details
## RequiredDeps: Details
Details_RaidInfo-TombOfSargeras.lua
@@ -1,81 +0,0 @@
do
local INSTANCE_EJID = 861
local INSTANCE_MAPID = 1648
local HDPATH = "Details_RaidInfo-TrialOfValor"
local LOADINGSCREEN_FILE, LOADINGSCREEN_COORDS = "LoadingScreen_TrialsofValor", {0, 1, 228/1024, 874/1024}
local EJ_LOREBG = "UI-EJ-LOREBG-TrialofValor"
local PORTRAIT_LIST = {
"UI-EJ-BOSS-Odyn",
"UI-EJ-BOSS-Guarm",
"UI-EJ-BOSS-Helya"
}
local ENCOUNTER_ID_CL = {
[1958] = 1, --Odyn
[1962] = 2, --Guarm
[2008] = 3, --Helya
}
local ENCOUNTER_ID_EJ = {
1819, 1830, 1829,
[1819] = 1, --Odyn
[1830] = 2, --Guarm
[1829] = 3, --Helya
}
function Details:InstallTrialOfValorRaidInfo()
--load encounter journal
EJ_SelectInstance (INSTANCE_EJID)
local InstanceName = EJ_GetInstanceInfo (INSTANCE_EJID)
--build the boss names list
local BOSSNAMES = {}
local ENCOUNTERS = {}
for i = 1, #PORTRAIT_LIST do
local bossName = EJ_GetEncounterInfoByIndex (i, INSTANCE_EJID)
if (bossName) then
tinsert (BOSSNAMES, bossName)
local encounterTable = {
boss = bossName,
portrait = "Interface\\EncounterJournal\\" .. PORTRAIT_LIST [i],
}
tinsert (ENCOUNTERS, encounterTable)
else
break
end
end
_detalhes:InstallEncounter ({
id = INSTANCE_MAPID, --map id
ej_id = INSTANCE_EJID, --encounter journal id
name = InstanceName,
icons = "Interface\\AddOns\\" .. HDPATH .. "\\boss_faces",
icon = "Interface\\AddOns\\" .. HDPATH .. "\\icon256x128",
is_raid = true,
backgroundFile = {file = "Interface\\Glues\\LOADINGSCREENS\\" .. LOADINGSCREEN_FILE, coords = LOADINGSCREEN_COORDS},
backgroundEJ = "Interface\\EncounterJournal\\" .. EJ_LOREBG,
encounter_ids = ENCOUNTER_ID_EJ,
encounter_ids2 = ENCOUNTER_ID_CL,
boss_names = BOSSNAMES,
encounters = ENCOUNTERS,
boss_ids = { --npc ids
},
})
--remove the install from the memory
Details.InstallTrialOfValorRaidInfo = nil
end
--install the encounter
Details:ScheduleTimer ("InstallTrialOfValorRaidInfo", 2)
end
@@ -1,6 +0,0 @@
## Interface: 70300
## Title: Details: Trial Of Valor
## Notes: Plugin for Details
## RequiredDeps: Details
Details_RaidInfo-TrialOfValor.lua
Binary file not shown.
@@ -14,7 +14,7 @@ local SOF = StreamOverlay.Frame
local fw = StreamOverlay.gump
local player_name
StreamOverlay.CurrentVersion = "v1.1"
StreamOverlay.CurrentVersion = "v1.2"
--> mantaing the tables for casts, has hash indexes of numbers pointing to tables, tables inside store data of the UNIT_CAST events
--> also mantain information about the cast, if is done, interrupted, channeled, instant.
@@ -1859,7 +1859,6 @@ function StreamOverlay.OpenOptionsPanel (from_options_panel)
end
options_frame.NewProfileButton = Details.gump:CreateButton (options_frame, add_profile, 60, 18, "New Profiile", _, _, _, _, _, _, Details.gump:GetTemplate ("dropdown", "OPTIONS_DROPDOWN_TEMPLATE"), Details.gump:GetTemplate ("font", "OPTIONS_FONT_TEMPLATE"))
options_frame.NewProfileButton:SetPoint ("left", dropdown_profile, "right", 4, 0)
end
options_frame:SetScript ("OnHide", function()
@@ -2013,7 +2012,8 @@ function StreamOverlay:OnEvent (_, event, ...)
SOF:RegisterEvent ("PLAYER_LOGOUT")
--profile name
local pname = UnitName ("player") .. " - " .. GetRealmName()
SOF.PlayerNameProfile = UnitName ("player") .. " - " .. GetRealmName()
local pname = SOF.PlayerNameProfile
--default if is first run
local next_pname = next (Details_StreamerDB.profiles or {})
Details_StreamerDB.characters [pname] = Details_StreamerDB.characters [pname] or next_pname or pname
@@ -2031,10 +2031,8 @@ function StreamOverlay:OnEvent (_, event, ...)
end
elseif (event == "PLAYER_LOGOUT") then
local pname = UnitName ("player") .. " - " .. GetRealmName()
local pname = SOF.PlayerNameProfile
Details_StreamerDB.profiles [ Details_StreamerDB.characters [pname] ] = StreamOverlay.db
end
end
+9 -1
View File
@@ -1295,7 +1295,12 @@ function _G._detalhes:Start()
if (lower_instance) then
lower_instance = _detalhes:GetInstance (lower_instance)
if (lower_instance and _detalhes.latest_news_saw ~= _detalhes.userversion) then
lower_instance:InstanceAlert (Loc ["STRING_VERSION_UPDATE"], {[[Interface\GossipFrame\AvailableQuestIcon]], 16, 16, false}, 60, {_detalhes.OpenNewsWindow})
C_Timer.After (10, function()
if (lower_instance:IsEnabled()) then
lower_instance:InstanceAlert (Loc ["STRING_VERSION_UPDATE"], {[[Interface\GossipFrame\AvailableQuestIcon]], 16, 16, false}, 60, {_detalhes.OpenNewsWindow}, true)
Details:Msg ("A new version has been installed: /details news")
end
end)
end
end
@@ -1825,6 +1830,9 @@ function _G._detalhes:Start()
C_Timer.After (2, function()
_detalhes:RefreshPlaterIntegration()
end)
--> override the overall data flag on this release only (remove on the release)
Details.overall_flag = 0x10
--[=[
--> suppress warnings for the first few seconds