diff options
author | Paul Gilbert | 2014-11-13 20:30:41 -0500 |
---|---|---|
committer | Paul Gilbert | 2014-12-12 22:32:24 -0500 |
commit | c4a5c36290e59d47272cb47244f294696cc6c5c1 (patch) | |
tree | eaaea2d076f706c5f4326af9088e7442ccef3292 | |
parent | 4ca5cc5ab4409601ed7458d08bf08c79c96dc8f7 (diff) | |
download | scummvm-rg350-c4a5c36290e59d47272cb47244f294696cc6c5c1.tar.gz scummvm-rg350-c4a5c36290e59d47272cb47244f294696cc6c5c1.tar.bz2 scummvm-rg350-c4a5c36290e59d47272cb47244f294696cc6c5c1.zip |
ACCESS: Fix crash when talking to pilot on the plane
-rw-r--r-- | engines/access/debugger.cpp | 2 | ||||
-rw-r--r-- | engines/access/scripts.cpp | 4 | ||||
-rw-r--r-- | engines/access/scripts.h | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/engines/access/debugger.cpp b/engines/access/debugger.cpp index 9a82168561..359b2e73a5 100644 --- a/engines/access/debugger.cpp +++ b/engines/access/debugger.cpp @@ -137,7 +137,7 @@ bool AmazonDebugger::Cmd_StartChapter(int argc, const char **argv) { chapterScript[2] = ROOM_SCRIPT / 256; chapterScript[3] = 0x80 + 75; // cmdChapter chapterScript[4] = strToInt(argv[1]); // chapter number - _vm->_scripts->setScript(new Resource(chapterScript, 5)); + _vm->_scripts->setScript(new Resource(chapterScript, 5), true); return false; } diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp index 34d5372b56..9f919484ef 100644 --- a/engines/access/scripts.cpp +++ b/engines/access/scripts.cpp @@ -43,10 +43,10 @@ Scripts::~Scripts() { freeScriptData(); } -void Scripts::setScript(Resource *res) { +void Scripts::setScript(Resource *res, bool restartFlag) { _resource = res; _data = res->_stream; - _endFlag = true; + _endFlag = restartFlag; } void Scripts::freeScriptData() { diff --git a/engines/access/scripts.h b/engines/access/scripts.h index 9860c7cde9..eaac996d4d 100644 --- a/engines/access/scripts.h +++ b/engines/access/scripts.h @@ -135,7 +135,7 @@ public: virtual ~Scripts(); - void setScript(Resource *data); + void setScript(Resource *data, bool restartFlag = false); void freeScriptData(); |