Finished the first 'Alpha Version' of the Coach feature
This commit is contained in:
+2
-98
@@ -990,95 +990,6 @@ function SlashCmdList.DETAILS (msg, editbox)
|
||||
print (Loc ["STRING_DETAILS1"] .. "diagnostic for character " .. rest .. " turned on.")
|
||||
return
|
||||
end
|
||||
|
||||
local current_combat = _detalhes.tabela_vigente
|
||||
|
||||
if (not _detalhes.DebugWindow) then
|
||||
_detalhes.DebugWindow = _detalhes.gump:CreateSimplePanel (UIParent, 800, 600, "Details! Debug", "DetailsDebugPanel")
|
||||
local TextBox = _detalhes.gump:NewSpecialLuaEditorEntry (_detalhes.DebugWindow, 760, 560, "text", "$parentTextEntry", true)
|
||||
TextBox:SetPoint ("center", _detalhes.DebugWindow, "center", 0, -10)
|
||||
TextBox:SetBackdrop ({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
|
||||
TextBox:SetBackdropColor (0, 0, 0, 0.9)
|
||||
TextBox:SetBackdropBorderColor (0, 0, 0, 1)
|
||||
_detalhes.DebugWindow.TextBox = TextBox
|
||||
end
|
||||
|
||||
local text = [[
|
||||
Hello World!
|
||||
Details! Damage Meter Debug
|
||||
Release Version: @VERSION Core Version: @CORE
|
||||
|
||||
Update Thread Status:
|
||||
Tick Rate: @TICKRATE
|
||||
Threat Health: @TICKHEALTH
|
||||
Last Tick: @TICKLAST
|
||||
Next Tick In: @TICKNEXT
|
||||
|
||||
Current Combat Status:
|
||||
ID: @COMBATID
|
||||
Container Status: @COMBATCONTAINERS
|
||||
Damage Container Actors: @COMBATDAMAGEACTORS actors found
|
||||
|
||||
Parser Status:
|
||||
Parser Health: @PARSERHEALTH
|
||||
Parser Capture Status: @PARSERCAPTURE
|
||||
|
||||
Lower Instance Status (window 1):
|
||||
Is Shown: @INSTANCESHOWN
|
||||
Segment Status: @INSTANCESEGMENT
|
||||
Damage Update Status: @INSTANCEDAMAGESTATUS
|
||||
|
||||
]]
|
||||
|
||||
text = text:gsub ([[@VERSION]], _detalhes.userversion)
|
||||
text = text:gsub ([[@CORE]], _detalhes.realversion)
|
||||
|
||||
text = text:gsub ([[@TICKRATE]], _detalhes.update_speed)
|
||||
text = text:gsub ([[@TICKHEALTH]], _detalhes:TimeLeft (_detalhes.atualizador) ~= 0 and "|cFF22FF22good|r" or "|cFFFF2222bad|r")
|
||||
text = text:gsub ([[@TICKLAST]], _detalhes.LastUpdateTick .. " (" .. _detalhes._tempo - _detalhes.LastUpdateTick .. " seconds ago)")
|
||||
text = text:gsub ([[@TICKNEXT]], _detalhes:TimeLeft (_detalhes.atualizador))
|
||||
|
||||
text = text:gsub ([[@COMBATID]], _detalhes.combat_id)
|
||||
text = text:gsub ([[@COMBATCONTAINERS]], _detalhes.tabela_vigente[1] and _detalhes.tabela_vigente[2] and _detalhes.tabela_vigente[3] and _detalhes.tabela_vigente[4] and "|cFF22FF22good|r" or "|cFFFF2222bad|r")
|
||||
text = text:gsub ([[@COMBATDAMAGEACTORS]], #_detalhes.tabela_vigente[1] and _detalhes.tabela_vigente[1]._ActorTable and #_detalhes.tabela_vigente[1]._ActorTable)
|
||||
|
||||
text = text:gsub ([[@PARSERHEALTH]], _detalhes.parser_frame:GetScript ("OnEvent") == _detalhes.OnParserEvent and "|cFF22FF22good|r" or "|cFFFF2222bad|r")
|
||||
|
||||
local captureStr = ""
|
||||
for _ , captureName in ipairs (_detalhes.capture_types) do
|
||||
if (_detalhes.capture_current [captureName]) then
|
||||
captureStr = captureStr .. " " .. captureName .. ": |cFF22FF22okay|r"
|
||||
else
|
||||
captureStr = captureStr .. " " .. captureName .. ": |cFFFF2222X|r"
|
||||
end
|
||||
end
|
||||
text = text:gsub ([[@PARSERCAPTURE]], captureStr)
|
||||
|
||||
local instance = _detalhes:GetLowerInstanceNumber()
|
||||
if (instance) then
|
||||
instance = _detalhes:GetInstance (instance)
|
||||
end
|
||||
|
||||
if (instance) then
|
||||
if (instance:IsEnabled()) then
|
||||
text = text:gsub ([[@INSTANCESHOWN]], "|cFF22FF22good|r")
|
||||
else
|
||||
text = text:gsub ([[@INSTANCESHOWN]], "|cFFFFFF22not visible|r")
|
||||
end
|
||||
|
||||
text = text:gsub ([[@INSTANCESEGMENT]], (instance.showing == _detalhes.tabela_vigente and "|cFF22FF22good|r" or "|cFFFFFF22isn't the current combat object|r") .. (" window segment: " .. instance:GetSegment()))
|
||||
|
||||
text = text:gsub ([[@INSTANCEDAMAGESTATUS]], (_detalhes._tempo - (_detalhes.LastFullDamageUpdate or 0)) < 3 and "|cFF22FF22good|r" or "|cFFFF2222last update registered is > than 3 seconds, is there actors to show?|r")
|
||||
else
|
||||
text = text:gsub ([[@INSTANCESHOWN]], "|cFFFFFF22not found|r")
|
||||
text = text:gsub ([[@INSTANCESEGMENT]], "|cFFFFFF22not found|r")
|
||||
text = text:gsub ([[@INSTANCEDAMAGESTATUS]], "|cFFFFFF22not found|r")
|
||||
|
||||
end
|
||||
|
||||
_detalhes.DebugWindow.TextBox:SetText (text)
|
||||
|
||||
_detalhes.DebugWindow:Show()
|
||||
end
|
||||
|
||||
--> debug combat log
|
||||
@@ -1591,15 +1502,8 @@ Damage Update Status: @INSTANCEDAMAGESTATUS
|
||||
return
|
||||
end
|
||||
|
||||
Details.coach.enabled = not Details.coach.enabled
|
||||
|
||||
if (Details.coach.enabled) then
|
||||
Details:Msg("Details! Coach enabled, good luck commander!")
|
||||
Details:Msg("[|cFFAAFFAADetails! Coach|r] raid leader stay outside the raid.")
|
||||
Details:Msg("[|cFFAAFFAADetails! Coach|r] assistants, at least one player inside the raid need to have assistant.")
|
||||
Details:Msg("[|cFFAAFFAADetails! Coach|r] players have an updated version of Details!.")
|
||||
Details.Coach.Server.EnableCoach()
|
||||
|
||||
if (not Details.coach.enabled) then
|
||||
Details.Coach.WelcomePanel()
|
||||
else
|
||||
Details:Msg("coach disabled.")
|
||||
Details.Coach.Disable()
|
||||
|
||||
Reference in New Issue
Block a user