aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
Diffstat (limited to 'engines')
-rw-r--r--engines/toon/anim.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/engines/toon/anim.cpp b/engines/toon/anim.cpp
index 84f6fa375c..a4eb1f210c 100644
--- a/engines/toon/anim.cpp
+++ b/engines/toon/anim.cpp
@@ -146,6 +146,9 @@ void Animation::drawFrame(Graphics::Surface &surface, int32 frame, int32 xx, int
if (_frames[frame]._ref != -1)
frame = _frames[frame]._ref;
+ if (!_frames[frame]._data)
+ return;
+
int32 rectX = _frames[frame]._x2 - _frames[frame]._x1;
int32 rectY = _frames[frame]._y2 - _frames[frame]._y1;
int32 offsX = 0;