Opened 18 years ago

Closed 18 years ago

#2690 closed defect (fixed)

INDY3 VGA: Crashes in Sewer

Reported by: SF/mthreepwood Owned by: Kirben
Priority: normal Component: Engine: SCUMM
Version: Keywords:
Cc: Game: Indiana Jones 3

Description

In the Venice Sewers, the game randomly crashes at some points. Sometimes it will crash when you change rooms for no apparent reason. When I go back to my saved game, it works fine until I get to another room.

I used Indy3 VGA (DOS/English) with 0.9.0pre 6/14/06 on my PC.

I attached a saved game.

Ticket imported from: #1507856. Ticket imported from: bugs/2690.

Attachments (3)

indy3.s04 (17.6 KB ) - added by SF/mthreepwood 18 years ago.
Saved Game in Sewer
flashlight.diff (1.4 KB ) - added by eriktorbjorn 18 years ago.
Possible patch against current SVN
flashlight_v2.diff (1.0 KB ) - added by Kirben 18 years ago.
Alternative patch

Download all attachments as: .zip

Change History (13)

by SF/mthreepwood, 18 years ago

Attachment: indy3.s04 added

Saved Game in Sewer

comment:1 by SF/bramvandijk, 18 years ago

I can confirm this, I had one crash, and when I came back nothing happend, so I didn't know whether to file a bugreport.

comment:2 by SF/mthreepwood, 18 years ago

Nothing happened to me either. But, it happened about five times. It got really annoying and I figured that when other people play the game, they will be annoyed too.

comment:3 by SF/mthreepwood, 18 years ago

Nothing happened to me either. But, it happened about five times. It got really annoying and I figured that when other people play the game, they will be annoyed too.

comment:4 by SF/mthreepwood, 18 years ago

Oops... I sent that twice by accident...

comment:5 by Kirben, 18 years ago

Does ScummVM report any error, when the crash occurs? you might need to run ScummVM via a command prompt or ms-dos prompt to see the error reported.

comment:6 by SF/mthreepwood, 18 years ago

Wow... I haven't used Command Prompt/MS-DOS in a while.

Anyway, there was an error message using command prompt. It was "ERROR: Gdi:: decompressBitmap: default case 175".

comment:7 by wjp, 18 years ago

There's an invalid write there which appears to be caused by the flashlight being undrawn after the room has changed. It tries to draw a black rectangle to the old screen.

It looks like _flashlight.isDrawn might have to be reset when the kMainVirtScreen changes, but I'm not sure how that should be done, considering initVirtScreen is in ScummEngine and the _flashlight is in ScummEngine_v5.

comment:8 by eriktorbjorn, 18 years ago

I've attached one possible patch, which I think should work.

by eriktorbjorn, 18 years ago

Attachment: flashlight.diff added

Possible patch against current SVN

comment:9 by Kirben, 18 years ago

Added alternative patch, which matches the code of original games. The original games would reset the flashlight in redrawBGAreas() when drawing more than a single strip, during a full screen redraw. Also I changed clearFlashlight() to non-virtual, since only a single version is required.

by Kirben, 18 years ago

Attachment: flashlight_v2.diff added

Alternative patch

comment:10 by Kirben, 18 years ago

Owner: set to Kirben
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.