diff options
author | Aki <please@ignore.pl> | 2022-03-23 22:57:42 +0100 |
---|---|---|
committer | Aki <please@ignore.pl> | 2022-03-23 22:57:42 +0100 |
commit | 6b2a17a2ccb1a0d45489208f7f23b9d6a65b110d (patch) | |
tree | 0c0c86871cdd51462617a946a9f35fe3501bd6a7 /Stars45/Campaign.cpp | |
parent | 9f9f2456d5ee0091bf171fae3ad321f82e5f2ca4 (diff) | |
download | starshatter-6b2a17a2ccb1a0d45489208f7f23b9d6a65b110d.zip starshatter-6b2a17a2ccb1a0d45489208f7f23b9d6a65b110d.tar.gz starshatter-6b2a17a2ccb1a0d45489208f7f23b9d6a65b110d.tar.bz2 |
Removed Clock from Game for now
While testing waters around exporting things out from Game to
GameWinDX9 I noticed that if both ContentBundle and Clock (primarily)
are removed from it, then the WinDX9 will be almost equivalent to base.
This is worrying mainly because I'm only fortified in seeing deep
relationships between various classes sadly including Video.
Diffstat (limited to 'Stars45/Campaign.cpp')
-rw-r--r-- | Stars45/Campaign.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Stars45/Campaign.cpp b/Stars45/Campaign.cpp index e41b24a..d6e4fb1 100644 --- a/Stars45/Campaign.cpp +++ b/Stars45/Campaign.cpp @@ -34,8 +34,8 @@ #include "Player.h" #include "ContentBundle.h" -#include "Game.h" #include "Bitmap.h" +#include "Clock.h" #include "DataLoader.h" #include "ParseUtil.h" #include "Random.h" @@ -409,7 +409,7 @@ Campaign::Unload() { SetStatus(CAMPAIGN_INIT); - Game::GetInstance()->GetClock()->ResetGameTime(); + Clock::GetInstance()->ResetGameTime(); StarSystem::SetBaseTime(0); startTime = Stardate(); @@ -1942,7 +1942,7 @@ Campaign::ExecFrame() else time += 20 * 3600; - StarSystem::SetBaseTime(startTime + time - Game::GetInstance()->GetClock()->GameTime()/1000.0); + StarSystem::SetBaseTime(startTime + time - Clock::GetInstance()->GameTime()/1000.0); } else { m.reset(); @@ -2044,7 +2044,7 @@ Campaign::StartMission() ::Print("\n\nCampaign Start Mission - %d. '%s'\n", m->Identity(), m->Name()); if (!scripted) { - long double gtime = (long double) Game::GetInstance()->GetClock()->GameTime() / 1000.0; + long double gtime = (long double) Clock::GetInstance()->GameTime() / 1000.0; long double base = startTime + m->Start() - 15 - gtime; StarSystem::SetBaseTime(base); @@ -2071,7 +2071,7 @@ Campaign::RollbackMission() if (m) { if (!scripted) { - long double gtime = (long double) Game::GetInstance()->GetClock()->GameTime() / 1000.0; + long double gtime = (long double) Clock::GetInstance()->GameTime() / 1000.0; long double base = startTime + m->Start() - 60 - gtime; StarSystem::SetBaseTime(base); |