From bf4af71e8475718be8c286ba35a7ebf15cc973ae Mon Sep 17 00:00:00 2001 From: Tercio Jose Date: Sat, 25 Mar 2023 11:50:22 -0300 Subject: [PATCH] Fix segments Lock; Unmerge Gem Stones --- boot.lua | 4 ++-- classes/class_instance.lua | 36 ++++++++++++++++++------------------ core/parser.lua | 2 ++ 3 files changed, 22 insertions(+), 20 deletions(-) diff --git a/boot.lua b/boot.lua index 78768a26b..29e5111a7 100644 --- a/boot.lua +++ b/boot.lua @@ -10,8 +10,8 @@ local addonName, Details222 = ... local version, build, date, tocversion = GetBuildInfo() - _detalhes.build_counter = 10727 - _detalhes.alpha_build_counter = 10727 --if this is higher than the regular counter, use it instead + _detalhes.build_counter = 10729 + _detalhes.alpha_build_counter = 10729 --if this is higher than the regular counter, use it instead _detalhes.dont_open_news = true _detalhes.game_version = version _detalhes.userversion = version .. " " .. _detalhes.build_counter diff --git a/classes/class_instance.lua b/classes/class_instance.lua index e678f458d..8a20ace07 100644 --- a/classes/class_instance.lua +++ b/classes/class_instance.lua @@ -2577,47 +2577,47 @@ function _detalhes:TrocaTabela(instance, segmentId, attributeId, subAttributeId, _detalhes:SendEvent("DETAILS_INSTANCE_CHANGESEGMENT", nil, instance, segmentId) if (_detalhes.instances_segments_locked and not fromInstanceStart) then - for _, instance in ipairs(_detalhes.tabela_instancias) do - if (instance.meu_id ~= instance.meu_id and instance.ativa and not instance._postponing_switch and not instance._postponing_current) then - if (instance:GetSegment() >= 0 and instance:GetSegment() ~= -1) then - if (instance.modo == 2 or instance.modo == 3) then + for _, thisInstance in ipairs(_detalhes.tabela_instancias) do + if (thisInstance.meu_id ~= instance.meu_id and thisInstance.ativa and not thisInstance._postponing_switch and not thisInstance._postponing_current) then + if (thisInstance:GetSegment() >= 0) then + if (thisInstance.modo == 2 or thisInstance.modo == 3) then --check if the instance is frozen - if (instance.freezed) then + if (thisInstance.freezed) then if (not fromInstanceStart) then - instance:UnFreeze() + thisInstance:UnFreeze() else - instance.freezed = false + thisInstance.freezed = false end end - instance.segmento = segmentId + thisInstance.segmento = segmentId if (segmentId == DETAILS_SEGMENTID_OVERALL) then - instance.showing = Details:GetOverallCombat() + thisInstance.showing = Details:GetOverallCombat() elseif (segmentId == DETAILS_SEGMENTID_CURRENT) then - instance.showing = Details:GetCurrentCombat() + thisInstance.showing = Details:GetCurrentCombat() else - instance.showing = Details:GetCombat(segmentId) + thisInstance.showing = Details:GetCombat(segmentId) end - if (not instance.showing) then + if (not thisInstance.showing) then if (not fromInstanceStart) then - instance:Freeze() + thisInstance:Freeze() end return end - instance.v_barras = true - instance.showing [attributeId].need_refresh = true + thisInstance.v_barras = true + thisInstance.showing [attributeId].need_refresh = true if (not _detalhes.initializing and not fromInstanceStart) then - instance:ResetaGump() - instance:RefreshMainWindow(true) + thisInstance:ResetaGump() + thisInstance:RefreshMainWindow(true) end - _detalhes:SendEvent("DETAILS_INSTANCE_CHANGESEGMENT", nil, instance, segmentId) + _detalhes:SendEvent("DETAILS_INSTANCE_CHANGESEGMENT", nil, thisInstance, segmentId) end end end diff --git a/core/parser.lua b/core/parser.lua index e23ac6878..d8b18e782 100755 --- a/core/parser.lua +++ b/core/parser.lua @@ -324,6 +324,7 @@ [228361] = 228360, --shadow priest void erruption --ring powers merged, https://gist.github.com/ljosberinn/65abe150133ff3a08cd70f840f7dd019 (by Gerrit Alex - WCL) + --[=[]] [403225] = 404884, -- Flame Licked Stone [404974] = 404884, -- Shining Obsidian Stone [405220] = 404884, -- Pestilent Plague Stone @@ -344,6 +345,7 @@ [403376] = 404884, -- Gleaming Iron Stone [403253] = 404884, -- Raging Magma Stone [403257] = 404884, -- Searing Smokey Stone + --]=] } end