Opened 8 months ago

Last modified 6 months ago

#15036 new feature request

SCUMM: Re-enable the missing answering machine message in Sam&Max

Reported by: GermanTribun Owned by:
Priority: normal Component: Engine: SCUMM
Version: Keywords:
Cc: Game: Sam and Max

Description

As TCRF wrote here about Sam & Max,

https://tcrf.net/Sam_%26_Max_Hit_the_Road#Local_Script_205_in_Room_7

the answering machine in the office actually has four messages, but for whatever reason, only three of those are picked at random. Is the fourth message also in the monster.sou? If yes, can the randomizer include all four of the messages?

Change History (1)

comment:1 by eriktorbjorn, 6 months ago

At least in the English CD version of the game, the other messages have a sound, like this:

[03D3] (B4)     printLine.msg(sound(0x1BD2BB, 0xA) + "<beep> Hello, is this the Saint Francis Pie Shop?" + wait() + "I'd like to order 200 lemon meringue pies and a small diet cola.")

(I don't remember off-hand what the parameters to sound() are, but I think the first one is the exact offset into the monster.sou file, or something like that.)

The fourth message, however, does not:

[04CE] (B4)     printLine.msg("<beep> Snork! <Grunt>" + wait() + "SQUEEEE!!!!" + wait() + "<Scronk> Yib!" + wait() + "<Click>")

I suppose it could be enabled for the floppy versions with something like this:

diff --git a/engines/scumm/script_v6.cpp b/engines/scumm/script_v6.cpp
index 4229dd37e5c..85614396dbe 100644
--- a/engines/scumm/script_v6.cpp
+++ b/engines/scumm/script_v6.cpp
@@ -1525,7 +1525,12 @@ void ScummEngine_v6::o6_loadRoomWithEgo() {
 
 void ScummEngine_v6::o6_getRandomNumber() {
        int rnd = _rnd.getRandomNumber(0x7fff);
-       rnd = rnd % (pop() + 1);
+       int max = pop();
+
+       if (enhancementEnabled(kEnhRestoredContent) && _game.id == GID_SAMNMAX && strcmp(_game.variant, "Floppy") == 0 && _currentRoom == 7 && vm.slot[_currentScript].number == 205)
+               max = 4;
+
+       rnd = rnd % max;
        if (VAR_RANDOM_NR != 0xFF)
                VAR(VAR_RANDOM_NR) = rnd;
        push(rnd);

But I don't own even a single floppy version, so I can't test it.

Note: See TracTickets for help on using tickets.