diff options
author | Aki <please@ignore.pl> | 2022-04-09 22:16:27 +0200 |
---|---|---|
committer | Aki <please@ignore.pl> | 2022-04-09 22:16:27 +0200 |
commit | 37d4fd61b47137b4f4bc6209c8ecec56981c2007 (patch) | |
tree | 575613d86589476ad0edaeba67609e66c238c895 /StarsEx/DebriefDlg.cpp | |
parent | aebbb4e305483efee3a714c443badd7edc60675b (diff) | |
download | starshatter-37d4fd61b47137b4f4bc6209c8ecec56981c2007.zip starshatter-37d4fd61b47137b4f4bc6209c8ecec56981c2007.tar.gz starshatter-37d4fd61b47137b4f4bc6209c8ecec56981c2007.tar.bz2 |
Removed dependency on Starshatter in some dialogs and mission gens
Diffstat (limited to 'StarsEx/DebriefDlg.cpp')
-rw-r--r-- | StarsEx/DebriefDlg.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/StarsEx/DebriefDlg.cpp b/StarsEx/DebriefDlg.cpp index a0a2b30..f6abdd1 100644 --- a/StarsEx/DebriefDlg.cpp +++ b/StarsEx/DebriefDlg.cpp @@ -13,7 +13,6 @@ #include "DebriefDlg.h" #include "PlanScreen.h" -#include "Starshatter.h" #include "Campaign.h" #include "Element.h" #include "Instruction.h" @@ -38,7 +37,6 @@ #include "ListBox.h" #include "Slider.h" #include "ParseUtil.h" -#include "Panic.h" #include "Game.h" // +--------------------------------------------------------------------+ @@ -355,20 +353,13 @@ DebriefDlg::OnClose(AWEvent* event) } else { - Starshatter* stars = Starshatter::GetInstance(); - - if (stars) { + if (auto game = Game::GetInstance()) { Mouse::Show(false); - Campaign* campaign = Campaign::GetCampaign(); if (campaign && campaign->GetCampaignId() < Campaign::SINGLE_MISSIONS) - stars->SetGameMode(Game::CMPN_MODE); + game->SetGameMode(Game::CMPN_MODE); else - stars->SetGameMode(Game::MENU_MODE); - } - - else { - Panic::Panic("DebriefDlg::OnClose() - Game instance not found"); + game->SetGameMode(Game::MENU_MODE); } } } |