aboutsummaryrefslogtreecommitdiff
path: root/engines/cine/various.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/cine/various.cpp')
-rw-r--r--engines/cine/various.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/engines/cine/various.cpp b/engines/cine/various.cpp
index 378437babf..bb97ba3188 100644
--- a/engines/cine/various.cpp
+++ b/engines/cine/various.cpp
@@ -171,6 +171,11 @@ void runObjectScript(int16 entryIdx) {
pNewElement->scriptPtr = (byte *)relTable[entryIdx].data;
pNewElement->scriptIdx = entryIdx;
+ if (g_cine->getGameType() == Cine::GType_OS) {
+ pNewElement->localVars[0] = relTable[entryIdx].runCount;
+ ++relTable[entryIdx].runCount;
+ }
+
computeScriptStack(pNewElement->scriptPtr, pNewElement->stack, relTable[entryIdx].size);
}