Opened 4 weeks ago

Closed 2 weeks ago

#11174 closed defect (fixed)

SCI: Hoyle 5 Bridge - save hand doesn't work

Reported by: misterhands Owned by: bluegr
Priority: normal Component: Engine: SCI
Keywords: Cc:
Game:

Description

Hoyle 5 Bridge Win
and
Hoyle Bridge Win

The save/restore hand feature in Hoyle 5 Bridge and Hoyle Bridge does not work properly. The save dialog is shown instead of the restore dialog when restoring a hand. Also after selecting a saved hand to restore (in the save dialog),
an error message is shown. Please see the pic.

Attachments (1)

scummvm00000.png (209.3 KB ) - added by misterhands 4 weeks ago.

Download all attachments as: .zip

Change History (12)

by misterhands, 4 weeks ago

Attachment: scummvm00000.png added

comment:1 by bluegr, 3 weeks ago

I couldn't find how to restore a saved hand. Could you tell me how to access this dialog?

comment:2 by misterhands, 3 weeks ago

You need to have "pre-saved hand" selected in the options.
Then on a new game the restore dialog is supposed to show up,
but it's the save dialog that does.

comment:3 by sluicebox, 3 weeks ago

The first problem is that Hoyle5 has a custom SRestore:doit. It takes a second parameter that identifies the card game. Only bridge and poker use save/restore. Poker isn't supported yet since it requires penguin16.dll which hasn't been reverse engineered.

Bridge calls save and restore from script 700 like this:

Save doit: "default save game" 700
Restore doit: "default save game" 700


Poker does the same from script 1190 and passes 1100 for the second parameter.

GuestAdditions::promptSaveRestoreDefault uses the parameter count to differentiate between save and load calls. It treats them both as Save because there's always more than one parameter.

I patched GuestAdditions::promptSaveRestoreDefault to use Restore mode to test if that took care of the error message, but it didn't, I also got the error about the file being invalid.

comment:4 by sluicebox <22204938+sluicebox@…>, 3 weeks ago

In 2ab281ff:

SCI32: Add HOYLE5 support for original Save/Load screens

Trac #11174

comment:5 by sluicebox <22204938+sluicebox@…>, 3 weeks ago

In 7c1fb8b:

SCI: Return correct value from kFileIOWriteString

Fixes corrupt save games in Hoyle5, bug #11174

comment:6 by sluicebox <22204938+sluicebox@…>, 3 weeks ago

In 3a88f618:

SCI32: Add HOYLE5 support for original Save/Load screens

Trac #11174

comment:7 by sluicebox <22204938+sluicebox@…>, 3 weeks ago

In edc37e1:

SCI: Return correct value from kFileIOWriteString

Fixes corrupt save games in Hoyle5, bug #11174

comment:8 by sluicebox, 3 weeks ago

Most of this is now fixed.

  • You can now enable the original save/load screens. You'll probably have to remove the game from ScummVM and re-add it for ScummVM to show that option in settings.
  • The save files are no longer corrupted so they can now be restored. Any that you've already saved won't work, you'll still get the message if you try to restore those.

When using the ScummVM save/restore screens, you will still get the Save screen when you should get the Restore screen. That's not fixed yet. But it will still restore a game correctly if you select an existing one.

comment:9 by misterhands, 3 weeks ago

Yes it works as you described. Using the original save/load screen, it works perfectly.
Thanks a lot!

comment:10 by Filippos Karapetis <bluegr@…>, 2 weeks ago

In 2df38d8b:

SCI32: Handle the special Bridge save/load screens in Hoyle 5

Fixes saving/loading the Bridge hands using the ScummVM save/load
screens - bug #11174

comment:11 by bluegr, 2 weeks ago

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