From 409f0b50d7a0fa7c9839b5ea775f398a4a54317f Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Fri, 13 Dec 2019 20:31:15 +0100 Subject: DIRECTOR: Implemented slow playback debug option --- engines/director/director.cpp | 1 + engines/director/director.h | 3 ++- engines/director/score.cpp | 3 +++ 3 files changed, 6 insertions(+), 1 deletion(-) (limited to 'engines') diff --git a/engines/director/director.cpp b/engines/director/director.cpp index 389db0f015..5d9c7c4ba4 100644 --- a/engines/director/director.cpp +++ b/engines/director/director.cpp @@ -48,6 +48,7 @@ DirectorEngine::DirectorEngine(OSystem *syst, const DirectorGameDescription *gam DebugMan.addDebugChannel(kDebugImages, "images", "Image drawing"); DebugMan.addDebugChannel(kDebugText, "text", "Text rendering"); DebugMan.addDebugChannel(kDebugEvents, "events", "Event processing"); + DebugMan.addDebugChannel(kDebugSlow, "slow", "Slow playback"); g_director = this; diff --git a/engines/director/director.h b/engines/director/director.h index 26824b44b5..f04781d7c8 100644 --- a/engines/director/director.h +++ b/engines/director/director.h @@ -63,7 +63,8 @@ enum { kDebugText = 1 << 4, kDebugEvents = 1 << 5, kDebugLingoParse = 1 << 6, - kDebugLingoCompileOnly = 1 << 7 + kDebugLingoCompileOnly = 1 << 7, + kDebugSlow = 1 << 8 }; struct MovieReference { diff --git a/engines/director/score.cpp b/engines/director/score.cpp index a3deb95433..84039bee27 100644 --- a/engines/director/score.cpp +++ b/engines/director/score.cpp @@ -1384,6 +1384,9 @@ void Score::update() { } _nextFrameTime = g_system->getMillis() + 1000.0 / (float)_currentFrameRate; + + if (debugChannelSet(-1, kDebugSlow)) + _nextFrameTime += 1000; } Sprite *Score::getSpriteById(uint16 id) { -- cgit v1.2.3