From 298c4063d260c022218e8d3cef7ab0089663c26d Mon Sep 17 00:00:00 2001 From: Barinade Date: Mon, 19 Dec 2022 16:08:59 -0600 Subject: [PATCH] til death invoke 2 rescores when switching scores while rescoring this is so that things dont visibly break and percentages suddenly make no sense --- .../ScreenEvaluation decorations/default.lua | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/Themes/Til Death/BGAnimations/ScreenEvaluation decorations/default.lua b/Themes/Til Death/BGAnimations/ScreenEvaluation decorations/default.lua index f1a42c6059..ba230e6d3a 100644 --- a/Themes/Til Death/BGAnimations/ScreenEvaluation decorations/default.lua +++ b/Themes/Til Death/BGAnimations/ScreenEvaluation decorations/default.lua @@ -201,7 +201,18 @@ local function scoreBoard(pn, position) ChangeScoreCommand = function(self, params) if params.score then score = params.score - setupNewScoreData(score) + if usingCustomWindows then + -- this is done very carefully to rescore a newly selected score once for wife3 and once for custom rescoring + unloadCustomWindowConfig() + usingCustomWindows = false + setupNewScoreData(score) + MESSAGEMAN:Broadcast("ScoreChanged") + usingCustomWindows = true + loadCurrentCustomWindowConfig() + setupNewScoreData(score) + else + setupNewScoreData(score) + end end if usingCustomWindows then @@ -282,10 +293,10 @@ local function scoreBoard(pn, position) if not usingCustomWindows then unloadCustomWindowConfig() MESSAGEMAN:Broadcast("UnloadedCustomWindow") + MESSAGEMAN:Broadcast("RecalculateGraphs", {judge=judge}) self:GetParent():playcommand("ChangeScore", {score = score}) MESSAGEMAN:Broadcast("SetFromDisplay", {score = score}) MESSAGEMAN:Broadcast("ForceWindow", {judge=judge}) - MESSAGEMAN:Broadcast("RecalculateGraphs", {judge=judge}) else loadCurrentCustomWindowConfig() MESSAGEMAN:Broadcast("RecalculateGraphs", {judge=judge})