From 8ad53851bcf745da720f3f0da9e204da4716b7f2 Mon Sep 17 00:00:00 2001 From: Bastien Bouclet Date: Sat, 1 Jul 2017 22:57:43 +0200 Subject: MOHAWK: Implement interrupting scripts for the new script manager --- engines/mohawk/riven_scripts.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'engines/mohawk/riven_scripts.h') diff --git a/engines/mohawk/riven_scripts.h b/engines/mohawk/riven_scripts.h index 37bdc062d4..6d422b858d 100644 --- a/engines/mohawk/riven_scripts.h +++ b/engines/mohawk/riven_scripts.h @@ -122,14 +122,11 @@ public: * Script execution must go through the ScriptManager, * this method should not be called directly. */ - void run(); + void run(RivenScriptManager *scriptManager); /** Print script details to the standard output */ void dumpScript(byte tabs); - /** Stop the script after the current command */ - void stopRunning() { _continueRunning = false; } - /** Append the commands of the other script to this script */ RivenScript &operator+=(const RivenScript &other); @@ -138,7 +135,6 @@ public: private: Common::Array _commands; - bool _continueRunning; }; /** Append the commands of the rhs Script to those of the lhs Script */ @@ -196,6 +192,8 @@ public: void stopAllScripts(); + bool stoppingAllScripts() const; + struct StoredMovieOpcode { RivenScriptPtr script; uint32 time; @@ -213,6 +211,7 @@ private: Common::Array _queue; bool _runningQueuedScripts; + bool _stoppingAllScripts; StoredMovieOpcode _storedMovieOpcode; -- cgit v1.2.3