From 26812078b5bd3d1ef272f4f830990e3ddefa77de Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Fri, 10 Jan 2020 16:58:34 +0100 Subject: DIRECTOR: Properly iterate over all movies when test-all is requested --- engines/director/director.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/engines/director/director.cpp b/engines/director/director.cpp index 13b86adb25..cc48b0492f 100644 --- a/engines/director/director.cpp +++ b/engines/director/director.cpp @@ -191,7 +191,8 @@ Common::Error DirectorEngine::run() { while (loop) { loop = false; - _currentScore->loadArchive(); + if (_currentScore) + _currentScore->loadArchive(); // If we came in a loop, then skip as requested if (!_nextMovie.frameS.empty()) { @@ -232,6 +233,11 @@ Common::Error DirectorEngine::run() { if (!mov) { warning("nextMovie: No score is loaded"); + if (getGameID() == GID_TESTALL) { + loop = true; + continue; + } + return Common::kNoError; } -- cgit v1.2.3