aboutsummaryrefslogtreecommitdiff
path: root/engines/bladerunner/time.cpp
diff options
context:
space:
mode:
authorThanasis Antoniou2019-07-17 19:08:43 +0300
committerThanasis Antoniou2019-07-17 19:09:15 +0300
commitcaa4578add35021bfbb00b5f81359592402096a3 (patch)
tree2133b0dd3f4e71324bafc1ca65699ba79483e512 /engines/bladerunner/time.cpp
parentd1ff73cbb381db1876e2dbdf0457c9efc76fcd1a (diff)
downloadscummvm-rg350-caa4578add35021bfbb00b5f81359592402096a3.tar.gz
scummvm-rg350-caa4578add35021bfbb00b5f81359592402096a3.tar.bz2
scummvm-rg350-caa4578add35021bfbb00b5f81359592402096a3.zip
BLADERUNNER: Use unsigned 32bit diff for time durations
Diffstat (limited to 'engines/bladerunner/time.cpp')
-rw-r--r--engines/bladerunner/time.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/engines/bladerunner/time.cpp b/engines/bladerunner/time.cpp
index ff7b6a78b5..ac2d6eac8b 100644
--- a/engines/bladerunner/time.cpp
+++ b/engines/bladerunner/time.cpp
@@ -34,16 +34,16 @@ Time::Time(BladeRunnerEngine *vm) {
_start = currentSystem();
_pauseCount = 0;
- _offset = 0;
- _pauseStart = 0;
+ _offset = 0u;
+ _pauseStart = 0u;
}
-int Time::currentSystem() {
+uint32 Time::currentSystem() {
return _vm->getTotalPlayTime();
}
-int Time::current() {
- int time = currentSystem() - _offset;
+uint32 Time::current() {
+ uint32 time = currentSystem() - _offset;
return time - _start;
}
@@ -54,7 +54,7 @@ int Time::pause() {
return ++_pauseCount;
}
-int Time::getPauseStart() {
+uint32 Time::getPauseStart() {
return _pauseStart;
}
@@ -75,7 +75,7 @@ bool Time::isLocked() {
// TODO Explore if it would make sense to only use the Engine methods for time accounting (pauseEngine, get/setTotalPlatTime)
// or do we need separated/independent time accounting and pausing?
void Time::resetPauseStart() {
- _offset = 0;
+ _offset = 0u;
_pauseStart = current();
}