Game Launcher: renamed is_loading to has_load_data for clarity

This commit is contained in:
Charles Dang 2021-01-05 23:47:26 +11:00
parent 7d4e5d5595
commit 8b6def9678
3 changed files with 4 additions and 4 deletions

View file

@ -656,7 +656,7 @@ bool game_launcher::play_render_image_mode()
return false;
}
bool game_launcher::is_loading() const
bool game_launcher::has_load_data() const
{
return utils::has_optional_value(load_data_);
}

View file

@ -87,7 +87,7 @@ public:
/** Runs unit tests specified on the command line */
unit_test_result unit_test();
bool is_loading() const;
bool has_load_data() const;
void clear_loaded_game();
bool load_game();
void set_test(const std::string& id);

View file

@ -814,7 +814,7 @@ static int do_gameloop(const std::vector<std::string>& args)
for(;;) {
statistics::fresh_stats();
if(!game->is_loading()) {
if(!game->has_load_data()) {
const config& cfg = config_manager.game_config().child("titlescreen_music");
if(cfg) {
for(const config& i : cfg.child_range("music")) {
@ -883,7 +883,7 @@ static int do_gameloop(const std::vector<std::string>& args)
game_launcher::RELOAD_GAME_DATA should_reload = game_launcher::RELOAD_DATA;
// If loading a game, skip the titlescreen entirely
if(game->is_loading() && game->load_game()) {
if(game->has_load_data() && game->load_game()) {
game->launch_game(should_reload);
continue;
}