[Scummvm-tracker] [ScummVM :: Bugs] #14907: SCI: KQ7: Crash on reaching chapter 4
ScummVM :: Bugs
trac at scummvm.org
Thu Feb 1 21:33:40 UTC 2024
#14907: SCI: KQ7: Crash on reaching chapter 4
-----------------------+-----------------------------
Reporter: Tricky1975 | Owner: (none)
Type: defect | Status: new
Priority: normal | Component: Engine: SCI
Version: | Resolution:
Keywords: | Game: King's Quest 7
-----------------------+-----------------------------
Comment (by m-kiewitz):
I doubt it's actually random, because it's a problem with a specific sound
resource.
That sound resource is tiny, so either a dummy, or even just a sound
resource which may reset some marker or whatever. I would have to take a
look at it.
So it may be the case that when you start that specific chapter, that this
sound resource is simply not accessed/played, because it's not needed in
that case, and thus can't cause this crash.
It could of course also be a broken sound resource.
As I said, our current SCI MIDI code is not accurate (unless someone
rewrote it in the last years). It uses time stamps to my knowledge (it's
actually using common ScummVM code, used by various engines), but Sierra's
SCI actually used byte offsets. This alone causes all sorts of problems,
but it's not simple to fix. There are quite a few open bugs because of it,
but the only proper solution is a rewrite of that subsystem.
For example the sound resource may say:
- change to instrument y
- now loop here
- play note x
and all on the same time stamp.
The loop command will currently save the time stamp.
So when the loop happens, the loop will start with "change to instrument
y", which is incorrect. It should start with "play note x".
This alone may make a song use the wrong instrument for a certain channel.
And there may be further problems with the code, but as I said it may even
be a broken sound resource. Broken resources sometimes happen in SCI
games, where the original SCI even read out of bounds. For a DOS
interpreter that's not really such a big problem. It's bad, but kinda
works. For ScummVM it's unacceptable. again: I would have to take a close
look at it, which I will probably do unless someone else does it first.
--
Ticket URL: <https://bugs.scummvm.org/ticket/14907#comment:4>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM
More information about the Scummvm-tracker
mailing list