aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/supernova/supernova.cpp10
-rw-r--r--engines/supernova/supernova.h1
2 files changed, 11 insertions, 0 deletions
diff --git a/engines/supernova/supernova.cpp b/engines/supernova/supernova.cpp
index bcc2347c30..b3c0adb8a0 100644
--- a/engines/supernova/supernova.cpp
+++ b/engines/supernova/supernova.cpp
@@ -119,6 +119,16 @@ Common::Error SupernovaEngine::run() {
return Common::kNoError;
}
+// Emulates DOS int 1A/00
+uint SupernovaEngine::getDOSTicks() {
+ TimeDate systemTime;
+ _system->getTimeAndDate(systemTime);
+
+ return static_cast<uint>((systemTime.tm_hour * 24 +
+ systemTime.tm_min * 60 +
+ systemTime.tm_sec) * 18.2065);
+}
+
void SupernovaEngine::updateEvents() {
Common::Event event;
diff --git a/engines/supernova/supernova.h b/engines/supernova/supernova.h
index f97cd401e9..9370e900b4 100644
--- a/engines/supernova/supernova.h
+++ b/engines/supernova/supernova.h
@@ -85,6 +85,7 @@ private:
byte _brightness;
uint _delay;
+ uint getDOSTicks();
void initData();
void initPalette();
void paletteFadeIn();