diff options
author | Eugene Sandulenko | 2019-12-25 14:26:11 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2019-12-25 14:26:11 +0100 |
commit | 3f392ca564be429715db75e89803dd6aa431798e (patch) | |
tree | c54887280cd64293bdc60aad70357d2c820bd338 /engines | |
parent | 3e296bc31bc89568178cfd084ea2d4631da43449 (diff) | |
download | scummvm-rg350-3f392ca564be429715db75e89803dd6aa431798e.tar.gz scummvm-rg350-3f392ca564be429715db75e89803dd6aa431798e.tar.bz2 scummvm-rg350-3f392ca564be429715db75e89803dd6aa431798e.zip |
DIRECTOR: Loop movies by default, added 'noloop' debug flag
Diffstat (limited to 'engines')
-rw-r--r-- | engines/director/director.cpp | 1 | ||||
-rw-r--r-- | engines/director/director.h | 3 | ||||
-rw-r--r-- | engines/director/score.cpp | 9 |
3 files changed, 11 insertions, 2 deletions
diff --git a/engines/director/director.cpp b/engines/director/director.cpp index 1d3cc4c0f5..e2c1e9fdc1 100644 --- a/engines/director/director.cpp +++ b/engines/director/director.cpp @@ -51,6 +51,7 @@ DirectorEngine::DirectorEngine(OSystem *syst, const DirectorGameDescription *gam DebugMan.addDebugChannel(kDebugText, "text", "Text rendering"); DebugMan.addDebugChannel(kDebugEvents, "events", "Event processing"); DebugMan.addDebugChannel(kDebugSlow, "slow", "Slow playback"); + DebugMan.addDebugChannel(kDebugNoLoop, "noloop", "Do not loop the playback"); DebugMan.addDebugChannel(kDebugBytecode, "bytecode", "Execute Lscr bytecode"); g_director = this; diff --git a/engines/director/director.h b/engines/director/director.h index aa2d797644..fa074d6c13 100644 --- a/engines/director/director.h +++ b/engines/director/director.h @@ -67,7 +67,8 @@ enum { kDebugLingoParse = 1 << 6, kDebugLingoCompileOnly = 1 << 7, kDebugSlow = 1 << 8, - kDebugBytecode = 1 << 9 + kDebugNoLoop = 1 << 9, + kDebugBytecode = 1 << 10 }; struct MovieReference { diff --git a/engines/director/score.cpp b/engines/director/score.cpp index 439c514dde..c4392b3822 100644 --- a/engines/director/score.cpp +++ b/engines/director/score.cpp @@ -1339,7 +1339,14 @@ void Score::startLoop() { _frames[_currentFrame]->prepareFrame(this); - while (!_stopPlay && _currentFrame < _frames.size()) { + while (!_stopPlay) { + if (_currentFrame >= _frames.size()) { + if (debugChannelSet(-1, kDebugNoLoop)) + break; + + _currentFrame = 0; + } + update(); if (_currentFrame < _frames.size()) |