Utility class for managing save game and high score functionality.
Definition game_save.hpp:56
static void delete_save()
Deletes the save game file.
Definition game_save.cpp:89
static void delete_highscore()
Deletes the high score file.
Definition game_save.cpp:97
static bool save_game(const SaveState &state)
Saves the current game state to a file.
Definition game_save.cpp:140
static bool highscore_exists()
Checks if a high score file exists.
Definition game_save.cpp:279
static bool save_exists()
Checks if a save file exists.
Definition game_save.cpp:268
static bool load_game(SaveState &state)
Loads a game state from file.
Definition game_save.cpp:179
static bool save_highscore(const HighScore &score)
Saves a high score to a file.
Definition game_save.cpp:110
static bool load_highscore(HighScore &score)
Loads high score data from file.
Definition game_save.cpp:227
Structure representing a high score record.
Definition game_save.hpp:43
char name[20]
Definition game_save.hpp:45
int score
Definition game_save.hpp:44
Structure representing the complete game state for saving/loading.
Definition game_save.hpp:21
float paddle2_y
Definition game_save.hpp:25
float ball_vel_y
Definition game_save.hpp:29
int score1
Definition game_save.hpp:22
float ball_x
Definition game_save.hpp:26
char player2_name[20]
Definition game_save.hpp:33
float ball_y
Definition game_save.hpp:27
int ball_type
Definition game_save.hpp:30
float paddle1_y
Definition game_save.hpp:24
char player1_name[20]
Definition game_save.hpp:32
float ball_vel_x
Definition game_save.hpp:28
int score2
Definition game_save.hpp:23