aboutsummaryrefslogtreecommitdiff
path: root/engines/hopkins/objects.cpp
diff options
context:
space:
mode:
authorStrangerke2013-04-21 00:26:16 +0200
committerStrangerke2013-04-21 00:26:41 +0200
commitb7d4ece827c45408b6fc04c5d44ea2046df4b340 (patch)
tree9fb5480d94be41d6e19b0797a1ff801d6f9ef4ad /engines/hopkins/objects.cpp
parent31e08b923cd120e0428a5b78eec0dd4d63e3c13d (diff)
downloadscummvm-rg350-b7d4ece827c45408b6fc04c5d44ea2046df4b340.tar.gz
scummvm-rg350-b7d4ece827c45408b6fc04c5d44ea2046df4b340.tar.bz2
scummvm-rg350-b7d4ece827c45408b6fc04c5d44ea2046df4b340.zip
HOPKINS: Add extra sanity check CID 1004008
Diffstat (limited to 'engines/hopkins/objects.cpp')
-rw-r--r--engines/hopkins/objects.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/engines/hopkins/objects.cpp b/engines/hopkins/objects.cpp
index f139ee55ab..6887b2947f 100644
--- a/engines/hopkins/objects.cpp
+++ b/engines/hopkins/objects.cpp
@@ -3087,6 +3087,7 @@ void ObjectsManager::setBobAnimDataIdx(int idx, int animIdx) {
* Set Hopkins animation
*/
void ObjectsManager::setBobAnimation(int idx) {
+ assert (idx < 36);
BobItem *bob = &_bob[idx];
if (!bob->_disabledAnimationFl)
return;
@@ -3102,6 +3103,7 @@ void ObjectsManager::setBobAnimation(int idx) {
* Stop Hopkins animation
*/
void ObjectsManager::stopBobAnimation(int idx) {
+ assert (idx < 36);
_bob[idx]._disabledAnimationFl = true;
}