Skip to content

Commit

Permalink
Game Browser: Invoke the logo scene when startup logos are found
Browse files Browse the repository at this point in the history
  • Loading branch information
Ghabry committed Oct 21, 2023
1 parent 4bb4dae commit 0c3b3ea
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions src/scene_gamebrowser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "game_system.h"
#include "input.h"
#include "player.h"
#include "scene_logo.h"
#include "scene_title.h"
#include "bitmap.h"
#include "audio.h"
Expand Down Expand Up @@ -213,11 +214,17 @@ void Scene_GameBrowser::BootGame() {
FileFinder::SetGameFilesystem(fs);
Player::CreateGameObjects();

game_loading = false;
load_window->SetVisible(false);

if (!FileFinder::FindImage("Logo", "LOGO1").empty()) {
// Delegate to Scene_Logo when a startup graphic was found
Scene::Push(std::make_shared<Scene_Logo>(1), true);
return;
}

if (!Player::startup_language.empty()) {
Player::translation.SelectLanguage(Player::startup_language);
}
Scene::Push(std::make_shared<Scene_Title>());

game_loading = false;
load_window->SetVisible(false);
}

0 comments on commit 0c3b3ea

Please sign in to comment.