From d6166000c902421a46f1239fa6bfeb81483d8bcd Mon Sep 17 00:00:00 2001 From: "Marco Antonio J. Costa" Date: Tue, 7 Oct 2025 22:50:03 -0300 Subject: [PATCH] rename fShowAtmPanelStartButton into something truthful there is no start button, this just controls whether to draw the four buttons in the Personnel tab of the laptop or not also get rid of lying comments also make it static, laptop.cpp doesn't use it at all --- Laptop/laptop.cpp | 6 ------ Laptop/personnel.cpp | 19 +++++++------------ 2 files changed, 7 insertions(+), 18 deletions(-) diff --git a/Laptop/laptop.cpp b/Laptop/laptop.cpp index 9844cbdc..220d808f 100644 --- a/Laptop/laptop.cpp +++ b/Laptop/laptop.cpp @@ -376,10 +376,6 @@ BOOLEAN fReDrawBookMarkInfo = FALSE; // show the 2 second info about bookmarks being accessed by clicking on web BOOLEAN fShowBookmarkInfo = FALSE; -// show start button for ATM panel? -extern BOOLEAN fShowAtmPanelStartButton; - - //TEMP! Disables the loadpending delay when switching b/n www pages BOOLEAN gfTemporaryDisablingOfLoadPendingFlag=FALSE; @@ -1093,8 +1089,6 @@ INT32 EnterLaptop() EnterLaptopInitLaptopPages(); InitalizeSubSitesList( ); - fShowAtmPanelStartButton = TRUE; - // lock cursor to screen if ( gGameExternalOptions.fLaptopMouseCaptured == TRUE ) { diff --git a/Laptop/personnel.cpp b/Laptop/personnel.cpp index b13f6eb0..bc202e2c 100644 --- a/Laptop/personnel.cpp +++ b/Laptop/personnel.cpp @@ -257,8 +257,7 @@ INT32 giCurrentUpperLeftPortraitNumber = 0; // which mode are we showing?..current team?...or deadly departed? BOOLEAN fCurrentTeamMode = TRUE; -// show the atm panel? -BOOLEAN fShowAtmPanelStartButton = TRUE; +static bool showPersonnelButtons{ true }; // create buttons for scrolling departures BOOLEAN fCreatePeronnelDepartureButton = FALSE; @@ -559,8 +558,7 @@ void EnterPersonnel( void ) // load graphics for screen LoadPersonnelGraphics( ); - // show atm panel - fShowAtmPanelStartButton = TRUE; + showPersonnelButtons = true; // create buttons needed CreateDestroyButtonsForPersonnelDepartures( ); @@ -598,8 +596,7 @@ void ExitPersonnel( void ) fCurrentTeamMode = FALSE; } - // get rid of atm panel buttons - fShowAtmPanelStartButton = FALSE; + showPersonnelButtons = false; CreateDestroyStartATMButton( ); gubPersonnelInfoState = PERSONNEL_STAT_BTN; @@ -5720,9 +5717,8 @@ BOOLEAN RenderAtmPanel( void ) void CreateDestroyStartATMButton( void ) { static BOOLEAN fCreated = FALSE; - // create/destroy atm start button as needed - - if( ( fCreated == FALSE ) && ( fShowAtmPanelStartButton == TRUE ) ) + + if( ( fCreated == FALSE ) && showPersonnelButtons ) { // not created, must create @@ -5761,7 +5757,7 @@ void CreateDestroyStartATMButton( void ) fCreated = TRUE; } - else if( ( fCreated == TRUE ) && ( fShowAtmPanelStartButton == FALSE ) ) + else if( ( fCreated == TRUE ) && !showPersonnelButtons ) { // stop showing for ( int i = 0; i < PERSONNEL_NUM_BTN; ++i ) @@ -6009,8 +6005,7 @@ BOOLEAN TransferFundsFromBankToMerc( SOLDIERTYPE *pSoldier, INT32 iCurrentBalanc void UpDateStateOfStartButton( void ) { - // start button being shown? - if (!fShowAtmPanelStartButton) + if (!showPersonnelButtons) return; for ( int i = 0; i < PERSONNEL_NUM_BTN; ++i )