mirror of
https://github.com/1dot13/source.git
synced 2026-09-09 14:46:05 +02:00
- Bugfix: SaveLoad-Dialog does not automatically jump to the correct page, when trying to load the last savegame (by Sionus)
o Before patch: openned first page, none saved game slot selected. o Now: openned page with last save game, slot with last saved game selected. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6711 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+17
-1
@@ -562,7 +562,7 @@ BOOLEAN NewEnterSaveLoadScreen()
|
|||||||
//if it is not the Quick Save slot, and we are loading
|
//if it is not the Quick Save slot, and we are loading
|
||||||
if( !gfSaveGame || gfSaveGame && gGameSettings.bLastSavedGameSlot != 0 )
|
if( !gfSaveGame || gfSaveGame && gGameSettings.bLastSavedGameSlot != 0 )
|
||||||
{
|
{
|
||||||
gbSelectedSaveLocation = gGameSettings.bLastSavedGameSlot;
|
gbSelectedSaveLocation = gGameSettings.bLastSavedGameSlot%NUM_SLOT;
|
||||||
gbSaveGameSelectedLocation[ gbSelectedSaveLocation ] = SLG_SELECTED_SLOT_GRAPHICS_NUMBER;
|
gbSaveGameSelectedLocation[ gbSelectedSaveLocation ] = SLG_SELECTED_SLOT_GRAPHICS_NUMBER;
|
||||||
|
|
||||||
//load the save gamed header string
|
//load the save gamed header string
|
||||||
@@ -848,6 +848,22 @@ BOOLEAN EnterSaveLoadScreen()
|
|||||||
|
|
||||||
gfGettingNameFromSaveLoadScreen = FALSE;
|
gfGettingNameFromSaveLoadScreen = FALSE;
|
||||||
|
|
||||||
|
//Go to page with last saved game
|
||||||
|
if ( gGameSettings.bLastSavedGameSlot >= NUM_SLOT)
|
||||||
|
{
|
||||||
|
PAGE_SLOT = gGameSettings.bLastSavedGameSlot/NUM_SLOT;
|
||||||
|
VAL_SLOT_START = (PAGE_SLOT * NUM_SLOT);
|
||||||
|
|
||||||
|
if ( PAGE_SLOT > 0 )
|
||||||
|
EnableButton( guiPrevButton );
|
||||||
|
|
||||||
|
if (PAGE_SLOT == MAX_PAGE_SLOT || PAGE_SLOT > MAX_PAGE_SLOT )
|
||||||
|
DisableButton( guiNextButton );
|
||||||
|
|
||||||
|
DestroySaveLoadTextInputBoxes();
|
||||||
|
NewEnterSaveLoadScreen();
|
||||||
|
}
|
||||||
|
|
||||||
return( TRUE );
|
return( TRUE );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user