diff options
author | Martin Kiewitz | 2016-02-14 22:43:52 +0100 |
---|---|---|
committer | Martin Kiewitz | 2016-02-14 22:43:52 +0100 |
commit | 7b75936f56fc5ea089e3fc957a113dc7577e832f (patch) | |
tree | 326117295350ac0b7b1807893969e2224a51e1df /engines/agi/agi.cpp | |
parent | dcbcbb2120de788207340e0b1bffae70397e1161 (diff) | |
download | scummvm-rg350-7b75936f56fc5ea089e3fc957a113dc7577e832f.tar.gz scummvm-rg350-7b75936f56fc5ea089e3fc957a113dc7577e832f.tar.bz2 scummvm-rg350-7b75936f56fc5ea089e3fc957a113dc7577e832f.zip |
AGI: Add heuristic to detect delay loops within scripts
And in that case poll events, delay for a few milliseconds and
update screen.
This somewhat worked before the graphics rewrite because of
a timer hack.
This one tries to detect actual inner loops.
Happens in at least Police Quest 1 when playing poker.
Diffstat (limited to 'engines/agi/agi.cpp')
-rw-r--r-- | engines/agi/agi.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/engines/agi/agi.cpp b/engines/agi/agi.cpp index fdc294a661..f149b0be95 100644 --- a/engines/agi/agi.cpp +++ b/engines/agi/agi.cpp @@ -401,6 +401,8 @@ AgiEngine::AgiEngine(OSystem *syst, const AGIGameDescription *gameDesc) : AgiBas setupOpcodes(); _game._curLogic = NULL; + _instructionCounter = 0; + resetGetVarSecondsHeuristic(); _lastSaveTime = 0; |