Skip to content

Commit

Permalink
tr2/savegame: resolve a cosmetic todo
Browse files Browse the repository at this point in the history
  • Loading branch information
rr- committed Nov 13, 2024
1 parent 0bbe8ba commit 62e1257
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 9 deletions.
3 changes: 3 additions & 0 deletions src/tr2/decomp/savegame.c
Original file line number Diff line number Diff line change
Expand Up @@ -933,9 +933,12 @@ int32_t __cdecl S_SaveGame(
&g_LoadGameRequester, slot_num, file_name, REQ_ALIGN_LEFT,
save_num_text, REQ_ALIGN_RIGHT);

g_SaveGameReqFlags1[slot_num] = g_RequesterFlags1[slot_num];
g_SaveGameReqFlags2[slot_num] = g_RequesterFlags2[slot_num];
g_SavedLevels[slot_num] = 1;
g_SaveCounter++;
g_SavedGames++;

return true;
}

Expand Down
6 changes: 0 additions & 6 deletions src/tr2/game/game.c
Original file line number Diff line number Diff line change
Expand Up @@ -127,12 +127,6 @@ int32_t __cdecl Game_Control(int32_t nframes, const bool demo_mode)
const int16_t slot_num = g_Inv_ExtraData[1];
S_SaveGame(
&g_SaveGame, sizeof(SAVEGAME_INFO), slot_num);
// TODO: move me inside S_SaveGame
g_SaveGameReqFlags1[slot_num] =
g_RequesterFlags1[slot_num];
g_SaveGameReqFlags2[slot_num] =
g_RequesterFlags2[slot_num];

S_SaveSettings();
} else {
return dir;
Expand Down
3 changes: 0 additions & 3 deletions src/tr2/game/savegame/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,6 @@ bool Savegame_Save(const int32_t slot_idx)
{
CreateSaveGameInfo();
S_SaveGame(&g_SaveGame, sizeof(SAVEGAME_INFO), slot_idx);
// TODO: move me inside S_SaveGame
g_SaveGameReqFlags1[slot_idx] = g_RequesterFlags1[slot_idx];
g_SaveGameReqFlags2[slot_idx] = g_RequesterFlags2[slot_idx];
GetSavedGamesList(&g_LoadGameRequester);
return true;
}

0 comments on commit 62e1257

Please sign in to comment.