aboutsummaryrefslogtreecommitdiff
path: root/engines/groovie/vdx.cpp
diff options
context:
space:
mode:
authorHenry Bush2008-11-30 21:17:58 +0000
committerHenry Bush2008-11-30 21:17:58 +0000
commitf10f151ff742801e12534bb052bd89419bf906cb (patch)
treec759215e129f48e3119aff19358ac7ac53375ae5 /engines/groovie/vdx.cpp
parentffaa47fb44896a14d776c792939e40dad3287521 (diff)
downloadscummvm-rg350-f10f151ff742801e12534bb052bd89419bf906cb.tar.gz
scummvm-rg350-f10f151ff742801e12534bb052bd89419bf906cb.tar.bz2
scummvm-rg350-f10f151ff742801e12534bb052bd89419bf906cb.zip
T7G: Reset origin at end of video: should fix seg fault after losing the microscope puzzle. Plus cleanup bitflag debugging.
svn-id: r35195
Diffstat (limited to 'engines/groovie/vdx.cpp')
-rw-r--r--engines/groovie/vdx.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/engines/groovie/vdx.cpp b/engines/groovie/vdx.cpp
index 1a260b4ab8..137333c362 100644
--- a/engines/groovie/vdx.cpp
+++ b/engines/groovie/vdx.cpp
@@ -53,13 +53,13 @@ uint16 VDXPlayer::loadInternal() {
if ((gDebugLevel == 11) || (Common::getEnabledSpecialDebugLevels() & engine_level)) {
int8 i;
debugN(1, "Groovie::VDX: New VDX: bitflags are ");
- for (i = 11; i >= 0; i--) {
+ for (i = 15; i >= 0; i--) {
debugN(1, "%d", _flags & (1 << i)? 1 : 0);
if (i % 4 == 0) {
debugN(1, " ");
}
}
- debug(1, " ");
+ debug(1, " <- 0 ");
}
// Flags:
// - 1 Puzzle piece? Skip palette, don't redraw full screen, draw still to b/ack buffer
@@ -176,7 +176,12 @@ bool VDXPlayer::playFrameInternal() {
// Report the end of the video if we reached the end of the file or if we
// just wanted to play one frame.
- return _file->eos() || _flagFirstFrame;
+ if (_file->eos() || _flagFirstFrame) {
+ _origX = _origY = 0;
+ return 1;
+ } else {
+ return 0;
+ }
}
static const uint16 vdxBlockMapLookup[] = {