aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorPaul Gilbert2015-05-04 13:41:01 -1000
committerPaul Gilbert2015-05-04 13:41:01 -1000
commit034e1384aad1ed91bb8879cded8e0247ae6f9000 (patch)
tree693d27cb2fc21fb7a5ae7bb6f3a3954c0aca4e3a /engines
parent8a9467b09aab38649a891934c17a7b15608ddf0a (diff)
downloadscummvm-rg350-034e1384aad1ed91bb8879cded8e0247ae6f9000.tar.gz
scummvm-rg350-034e1384aad1ed91bb8879cded8e0247ae6f9000.tar.bz2
scummvm-rg350-034e1384aad1ed91bb8879cded8e0247ae6f9000.zip
SHERLOCK: Fix picking up Sarah's effects in Morgue
Diffstat (limited to 'engines')
-rw-r--r--engines/sherlock/scene.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/engines/sherlock/scene.cpp b/engines/sherlock/scene.cpp
index 8a47707aea..857dff4951 100644
--- a/engines/sherlock/scene.cpp
+++ b/engines/sherlock/scene.cpp
@@ -1386,7 +1386,11 @@ void Scene::doBgAnim() {
for (int idx = _canimShapes.size() - 1; idx >= 0; --idx) {
Object &o = _canimShapes[idx];
- if (o._type == REMOVE) {
+
+ if (o._type == INVALID) {
+ // Anim shape was invalidated by checkEndOfSequence, so at this point we can remove it
+ _canimShapes.remove_at(idx);
+ } else if (o._type == REMOVE) {
if (_goToScene == -1)
screen.slamArea(o._position.x, o._position.y, o._delta.x, o._delta.y);