aboutsummaryrefslogtreecommitdiff
path: root/queen/graphics.cpp
diff options
context:
space:
mode:
authorGregory Montoir2004-01-14 14:34:05 +0000
committerGregory Montoir2004-01-14 14:34:05 +0000
commit6c78f2a6b801ae8a8efb7f9db9bf0213ce3eb759 (patch)
treeaaf89d79270a296bb9beab7d563639f20acbf260 /queen/graphics.cpp
parent9f8caa6889c5504edb279cacc524c142eb5829d1 (diff)
downloadscummvm-rg350-6c78f2a6b801ae8a8efb7f9db9bf0213ce3eb759.tar.gz
scummvm-rg350-6c78f2a6b801ae8a8efb7f9db9bf0213ce3eb759.tar.bz2
scummvm-rg350-6c78f2a6b801ae8a8efb7f9db9bf0213ce3eb759.zip
- tweaked a bit walking functions to make persons stop walking when a cutaway is canceled
- removed unpack to bob frame 2 (as it is never used) - changed some error() calls to assert() - minor cleanups svn-id: r12385
Diffstat (limited to 'queen/graphics.cpp')
-rw-r--r--queen/graphics.cpp11
1 files changed, 2 insertions, 9 deletions
diff --git a/queen/graphics.cpp b/queen/graphics.cpp
index 5dc79f966e..fd13de9202 100644
--- a/queen/graphics.cpp
+++ b/queen/graphics.cpp
@@ -407,12 +407,8 @@ void Graphics::stopBobs() {
}
BobSlot *Graphics::bob(int index) {
- if (index < MAX_BOBS_NUMBER)
- return _bobs + index;
- else {
- error("QueenGraphics::bob called with index = %i but MAX_BOBS_NUMBER = %i",
- index, MAX_BOBS_NUMBER);
- }
+ assert(index < MAX_BOBS_NUMBER);
+ return _bobs + index;
}
void Graphics::setBobText(
@@ -846,7 +842,6 @@ uint16 Graphics::refreshObject(uint16 obj) {
curImage += pgd->lastFrame - 1;
} else if (lastFrame != 0) {
// turn on an animated bob
- _vm->bankMan()->unpack(pgd->firstFrame, 2, 15);
pbs->animating = false;
uint16 firstImage = curImage;
--curImage;
@@ -861,8 +856,6 @@ uint16 Graphics::refreshObject(uint16 obj) {
pbs->animNormal(firstImage, curImage, pgd->speed / 4, rebound, false);
}
} else {
- // frame 2 is used as a buffer frame to prevent BOB flickering
- _vm->bankMan()->unpack(pgd->firstFrame, 2, 15);
_vm->bankMan()->unpack(pgd->firstFrame, curImage, 15);
pbs->curPos(pgd->x, pgd->y);
pbs->frameNum = curImage;