From e8b9f39ff5469378648c8886e8348dbc7673944c Mon Sep 17 00:00:00 2001 From: Tercio Jose Date: Fri, 11 Oct 2024 10:13:15 -0300 Subject: [PATCH] Added into the overall m+ combat, the value for the total runtime of the dungeon ".elapsed_time" --- functions/mythicdungeon/segments.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/functions/mythicdungeon/segments.lua b/functions/mythicdungeon/segments.lua index 7d9f741c6..7360715e3 100644 --- a/functions/mythicdungeon/segments.lua +++ b/functions/mythicdungeon/segments.lua @@ -211,6 +211,7 @@ function DetailsMythicPlusFrame.MergeSegmentsOnEnd() --~merge Details222.StartCombat() --get the current combat just created and the table with all past segments + ---@type combat local newCombat = Details:GetCurrentCombat() local segmentsTable = Details:GetCombatSegments() @@ -253,7 +254,8 @@ function DetailsMythicPlusFrame.MergeSegmentsOnEnd() --~merge EndedAt = Details.MythicPlus.EndedAt, --the end of the run WorldStateTimerStart = Details222.MythicPlus.WorldStateTimerStartAt, WorldStateTimerEnd = Details222.MythicPlus.WorldStateTimerEndAt, - RunTime = Details222.MythicPlus.time, + RunTime = Details222.MythicPlus.time, --this is the time that discounted the deaths penalty + TotalTime = Details222.MythicPlus.ElapsedTime, --this is the total time of the run TimeInCombat = timeInCombat, SegmentID = "overall", --segment number within the dungeon RunID = Details.mythic_dungeon_id, @@ -324,6 +326,7 @@ function DetailsMythicPlusFrame.MergeSegmentsOnEnd() --~merge --check if both values are valid, this can get invalid if the player leaves the dungeon before the timer ends or the game crashes if (type(Details222.MythicPlus.time) == "number") then newCombat.run_time = Details222.MythicPlus.time + newCombat.elapsed_time = Details222.MythicPlus.ElapsedTime Details222.MythicPlus.LogStep("GetCompletionInfo() Found, Time: " .. Details222.MythicPlus.time) elseif (newCombat.is_mythic_dungeon.WorldStateTimerEnd and newCombat.is_mythic_dungeon.WorldStateTimerStart) then