Opened 7 years ago

Closed 4 years ago

#6053 closed defect (invalid)

TINSEL: DW2 Crash at CD swapping screen

Reported by: SF/marius75 Owned by: dreammaster
Priority: low Component: Engine: Tinsel
Keywords: Cc:
Game: Discworld II

Description

Playing through the game and finish disk 1 with no problems. It asks to insert disk 2 and crashes back to desktop after a few seconds on the insert CD 2 screen.

Ticket imported from: #3534630. Ticket imported from: bugs/6053.

Attachments (1)

dw2-gb.018 (2.4 KB ) - added by digitall 7 years ago.
Savegame for replication

Download all attachments as: .zip

Change History (18)

comment:1 by digitall, 7 years ago

Summary: Loading CD 2 screen crashTINSEL: DW2 Crash at CD swapping screen

comment:2 by digitall, 7 years ago

marius75: Thank you for the bug report.

Unfortunately you have not provided sufficient information to allow us to investigate this bug. Please can you provide the following information:
1. What Operating System are you using e.g. Windows XP, Mac OSX 10.6, Ubuntu Linux etc.?
2. What release of ScummVM are you using e.g. v1.4.1 (which is the current stable release)?
3. What exact version of Discworld 2 do you have e.g. UK/European, US, French, German etc.?
4. Please attach a savegame just prior to the point of the CD swap to this bug, so that we can load this and trigger the swap.

comment:3 by dreammaster, 7 years ago

This tracker item is pending response by the submitter; we
cannot continue processing it before that happens. As a
consequence, its status has been set to "Pending". It will
automatically revert to "Open" once a new comment is made to
this item. If no response is made within 14 days, it will
automatically be closed.

Thank you.

comment:4 by dreammaster, 7 years ago

Status: newpending

comment:5 by digitall, 7 years ago

Attaching savegame at point of swap to aid replication.

Managed to replicate this on Linux x86_32 with latest Git master by changing a symbolic link with a cdrom directory for dw2 directory from cd1/dw2 to cd2/dw2 i.e. rm cdrom/dw2 && ln -s cd2/dw2 cdrom/dw2

This is not a "crash", but an engine exit with a bunch of assertions:
WARNING: FSNode::createReadStream: 'english.smp' does not exist!
WARNING: FSDirectory::createReadStreamForMember: Can't create stream for file 'english.smp'!
WARNING: FSNode::createReadStream: 'english.smp' does not exist!
WARNING: FSDirectory::createReadStreamForMember: Can't create stream for file 'english.smp'!
Cannot find file project.scn!

by digitall, 7 years ago

Attachment: dw2-gb.018 added

Savegame for replication

comment:6 by digitall, 7 years ago

marius75: The usual method is to copy both CDs contents to a folder on your HDD and merge them, rather than playing the game from the CDs, though this should be a supported configuration. In the interim, you should be able to use this solution:
http://wiki.scummvm.org/index.php/User_Manual/Installing_a_game_for_use_with_ScummVM#Multi-CD_games
http://wiki.scummvm.org/index.php/Datafiles#Discworld_2:_Missing_Presumed_....21.3F

comment:7 by bluegr, 7 years ago

This has not been closed automatically, and it's pretty old now. Closing manually.

comment:8 by bluegr, 7 years ago

Status: pendingclosed

comment:9 by digitall, 7 years ago

Priority: normallow
Status: closednew

comment:10 by digitall, 7 years ago

Reopening this as the pending status was relating to the user confirming whether the workaround was acceptable.

This bug is confirmed, but has a lower priority as most users will copy the CD contents to a single directory on HDD as explained previously i.e. it only affects users running from the original CDs, so have set this to a lower priority.

It will need a bisection to be done with the replication method I suggested to locate when this function was broken...

comment:11 by digitall, 7 years ago

Ah... 86debbd679d20f1188d2ba015e9d108cbbc85f1a sheds some light on this issue:
Author: dreammaster 2009-04-25 07:42:01

Added code to enable Discworld 2 to play directly from the CD (only the first CD - Cd swap still doesn't work) or from files copied to the hard disk without the .smp/txt/idx files being properly renamed (again only for the first Cd).

svn-id: r40141

dreammaster: Has this ever been fixed to work?

comment:12 by digitall, 7 years ago

Owner: set to dreammaster

comment:13 by SF/cjacobi, 6 years ago

It's about 1½ years someone was reporting on this but I still see the problem described here. The current back trace of me identifies this line (currently in engines/tinsel/sound.cpp at line 266, I'm using scummvm 1.4.1 with Ubuntu precise and there it was at engines/tinsel/sound.cpp line 244):

// make sure id is in range
assert(id > 0 && id < _sampleIndexLen);

Here the current values of the variables in my environment (I'm playing the german version):
id -> 9453
_sampleIndexLen -> 0

My first guess is that the variable _sampleIndexLen was not initialized correctly, maybe in the method openSampleFiles().

comment:14 by digitall, 6 years ago

@Carsten: The current stable ScummVM release version is v1.6.0, so v1.4.1 is VERY out of date.

Unfortunately, Ubuntu is based off Debian and that is still on v1.4.1. Using an LTS release means getting older versions of packages...

I suggest you uninstall the Ubuntu repository package of ScummVM and either install a build you have compiled yourself from the latest source code or at least the v1.6.0 tarball on the download page.

As I indicated earlier, this is still broken in recent builds, but not for the reason you indicated. The "official" workaround is to copy the contents of both CDs to a single directory on your HDD, merge them and then run DW2 from the resulting datafiles.

comment:15 by SF/cjacobi, 6 years ago

@digitall: Well, I actually do play the game with the CD's whole content residing on my HDD. I also renamed the language files according to http://wiki.scummvm.org/index.php/Datafiles#Discworld_2:Missing_Presumed....21.3F . But right in the first scene after the "Swap-CD" sequence the mentioned crash occurs and I see it related to the problem described here.
I guess the variable _sampleIndexLen is a private variable of the class and is initialized as an object derived from the class is instantiated. Is it possible to find out which game file this is related to? I am on an old version, but for me this looks as if the bug is still apparent to the newest version (I also tried it with the version 1.6.0 that comes with Ubuntu 14.04 and the result was about the same).

comment:16 by SF/cjacobi, 6 years ago

Ok, sorry .... just found my local problem:

@laptop:~/Spiele/Discworld_II$ ls -l german2.{smp,idx}
-rw-r--r-- 1 xxxxxxx users 0 Aug 17 2012 german2.idx
-rw-r--r-- 1 xxxxxxx users 0 Aug 17 2012 german2.smp

The files I copied down from the CD were empty! I'll take a closer look at the original files from the CD ... sorry for having bothered you with this!

comment:17 by sev-, 4 years ago

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.