From f1d54316605efade8800aa9d7a0a3e1f69aa6734 Mon Sep 17 00:00:00 2001 From: "Marco Antonio J. Costa" Date: Sun, 2 Aug 2026 13:54:22 -0300 Subject: [PATCH] Remove dead gfTransitionMapscreenToAutoResolve flag MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The flag was initialized FALSE (mapscreen.cpp), read once in HandlePreBattleInterfaceStates, and only ever set FALSE — never TRUE anywhere in the tree. Its else-if branch was unreachable and its body did nothing but re-clear the always-false flag. Verify: grep 'gfTransitionMapscreenToAutoResolve' across the tree now hits nothing. Build: JA2. Co-Authored-By: Claude Opus 4.8 --- Strategic/PreBattle Interface.cpp | 5 ----- Strategic/mapscreen.cpp | 4 ---- 2 files changed, 9 deletions(-) diff --git a/Strategic/PreBattle Interface.cpp b/Strategic/PreBattle Interface.cpp index 2f9c87a8c..895760a6d 100644 --- a/Strategic/PreBattle Interface.cpp +++ b/Strategic/PreBattle Interface.cpp @@ -54,7 +54,6 @@ extern void InitializeTacticalStatusAtBattleStart(); extern BOOLEAN gfDelayAutoResolveStart; -extern BOOLEAN gfTransitionMapscreenToAutoResolve; extern UILayout_Map UI_MAP; #ifdef JA2BETAVERSION @@ -2711,8 +2710,4 @@ void HandlePreBattleInterfaceStates() gfAutomaticallyStartAutoResolve = FALSE; ActivateAutomaticAutoResolveStart(); } - else if( gfTransitionMapscreenToAutoResolve ) - { - gfTransitionMapscreenToAutoResolve = FALSE; - } } diff --git a/Strategic/mapscreen.cpp b/Strategic/mapscreen.cpp index d36b6c582..a1e35f2f9 100644 --- a/Strategic/mapscreen.cpp +++ b/Strategic/mapscreen.cpp @@ -466,10 +466,6 @@ BOOLEAN gfCharacterListInited = FALSE; BOOLEAN gfGlowTimerExpired = FALSE; -//not required to be saved. The flag is set to allow mapscreen to render once, then transition the -//current tactical battle into autoresolve. -BOOLEAN gfTransitionMapscreenToAutoResolve = FALSE; - BOOLEAN gfSkyriderEmptyHelpGiven = FALSE; BOOLEAN gfRequestGiveSkyriderNewDestination = FALSE;