Opened 15 years ago

Closed 6 months ago

#4494 closed defect (fixed)

SCUMM: Indy3 (MAC) - Music Does Not Play When Loading Games

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

Description

Indy3 Mac (Mac OS X 10.5, 1.0.0svn)

When loading a saved game with music in the background, the game does not play the music. (ie Venice, choosing the grail). I'm uploading a save from each of those spots where sound should be playing.

Ticket imported from: #2829338. Ticket imported from: bugs/4494.

Attachments (2)

indy3-ega-mac.s08 (11.6 KB ) - added by SF/mthreepwood 15 years ago.
Grail Scene Saved Game
indy3-ega-mac.s10 (11.7 KB ) - added by SF/mthreepwood 15 years ago.
Venice Saved Game

Download all attachments as: .zip

Change History (12)

by SF/mthreepwood, 15 years ago

Attachment: indy3-ega-mac.s08 added

Grail Scene Saved Game

by SF/mthreepwood, 15 years ago

Attachment: indy3-ega-mac.s10 added

Venice Saved Game

comment:1 by raziel-, 4 years ago

Summary: INDY3 MAC: Music Does Not Play When Loading GamesSCUMM: Indy3 (MAC) - Music Does Not Play When Loading Games

comment:2 by athrxx, 3 years ago

Owner: set to eriktorbjorn
Resolution: pending
Status: newpending

Is this one still valid?

eriktorbjorn recently made great improvements to Indy3 MAC.

comment:3 by athrxx, 3 years ago

Owner: changed from eriktorbjorn to athrxx

comment:4 by eriktorbjorn, 3 years ago

My improvements were mainly about graphics. I don't know anything about the sound, though I have a feeling the music doesn't sound at all like a real Mac would. So any music glitch probably remains.

comment:5 by dwatteau, 21 months ago

Yeah that issue is still true as of today, e.g. with the save I've made today for Trac#13908, when Indy and Elsa travel to Castle Brunwald.

comment:6 by eriktorbjorn, 10 months ago

I tried it in Mini vMac with the catacombs music, and it appears it doesn't save the position in the song, just which song it was playing. So that seems like it should be pretty easy to fix.

comment:7 by eriktorbjorn, 10 months ago

But from what I understand, this wouldn't be just an issue for the Mac version of Indiana Jones and the Last Crusade. It's Player_V2 or Player_V2Base who should do the saving/loading, I think? The Mac version definitely uses Player_V2, and it doesn't implement saveLoadWithSerializer().

Player_V2Base is the base class for Player_V2 and Player_V2CMS, but not for Player_V2A. (So in a hypothetical future, there would be a Player_V2MAC that emulates the particular sound of the Macintosh 4-voice synth, but which otherwise behaves like Player_V2?

So which games would that affect?

Games with version 2-4 with PC Speaker or PCjr music use Player_V2. That would be:

  • Maniac Mansion (enhanced)
  • Zak McKracken and the Alien Mindbenders (enhanced)
  • Indiana Jones and the Last Crusade (all versions except FM Towns)
  • Loom (all versions without CD audio tracks)
  • The Secret of Monkey Island (all versions except the Mac version and the ones with CD audio tracks)

There may be others, with other music drivers that also don't save/restore state.

To test, I started The Secret of Monkey Island (VGA) with AdLib music, entered the SCUMM bar and saved. When I loaded, the music resumed from where it was saved. When I tried it with CMS music (it doesn't play at all with PCjr) it did not resume at all when loading.

comment:8 by athrxx, 10 months ago

For the <=V3 games the sounds will usually be restored from script after loading (see ScummEngine_v3::scummLoop_handleSaveLoad()): It works for all these games like ZAK, INDY3 etc., unless you save your game in an unusual situation (=using the GMM save in a place where the original does not allow it). Unfortunately, as you can see from the code, we do not do the postload fix on Mac (simply because the code/scripts are different and we don't know what to do there).

For the games that don't use scripted saves (>=V4) the sounds have to be restored from the savegames. Our ims driver implementations usually do that, but not the CMS one. Also, it is still true that it is not a good idea to load games with a different sound setting than the one used for the save.

comment:9 by eriktorbjorn, 6 months ago

@athrxx I saw you fixed music saving/loading. (Thanks!) Does that mean this can be closed now, or are there still things that need more work?

comment:10 by athrxx, 6 months ago

Resolution: pendingfixed
Status: pendingclosed

Yes, this should work as intended, now.
I am closing the ticket.

Note: See TracTickets for help on using tickets.