diff options
author | Vhati | 2018-12-24 09:30:44 -0500 |
---|---|---|
committer | Filippos Karapetis | 2018-12-28 18:11:31 +0200 |
commit | 2d75c6b271e71168bb42024606f4b7fc510d1751 (patch) | |
tree | e96e8fd0944e9217e0784358d414bd458c75a13f /engines/sci/engine | |
parent | 8f2da7086c74220869d8da0ae5c01b2999da37fd (diff) | |
download | scummvm-rg350-2d75c6b271e71168bb42024606f4b7fc510d1751.tar.gz scummvm-rg350-2d75c6b271e71168bb42024606f4b7fc510d1751.tar.bz2 scummvm-rg350-2d75c6b271e71168bb42024606f4b7fc510d1751.zip |
SCI32: Fix QFG4 Rusalka flowers dialogue
Fixes mixed up text/audio when giving her flowers, bug #10849
Diffstat (limited to 'engines/sci/engine')
-rw-r--r-- | engines/sci/engine/message.cpp | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/engines/sci/engine/message.cpp b/engines/sci/engine/message.cpp index aa961c9a85..5d1607ccee 100644 --- a/engines/sci/engine/message.cpp +++ b/engines/sci/engine/message.cpp @@ -255,6 +255,42 @@ bool MessageState::getRecord(CursorStack &stack, bool recurse, MessageRecord &re t.verb = 1; } + if (g_sci->getGameId() == GID_QFG4 && g_sci->isCD() && stack.getModule() == 520 && + t.noun == 2 && t.verb == 59 && t.cond == 0) { + // The CD edition mangled the Rusalka flowers dialogue. - bug #10849 + // In the floppy edition, there are 3 lines, the first from + // the narrator, then two from Rusalka. The CD edition omits + // narration and only has the 3rd text, with the 2nd audio! The + // 3rd audio is orphaned but available. + // + // We only restore Rusalka's lines, providing the correct text + // for seq:1 to match the audio. We respond to seq:2 requests + // with Rusalka's last text. The orphaned audio (seq:3) has its + // tuple adjusted to seq:2 in resource_audio.cpp. + if (t.seq == 1) { + record.tuple = t; + record.refTuple = MessageTuple(); + record.talker = 28; + record.string = "Thank you for the beautiful flowers. No one has been so nice to me since I can remember."; + record.length = 89; + delete reader; + return true; + } else if (t.seq == 2) { + // The CD edition ships with this text at seq:1. + // Look it up instead of hardcoding. + t.seq = 1; + if (!reader->findRecord(t, record)) { + delete reader; + return false; + } + t.seq = 2; // Prevent an endless 2=1 -> 2=1 -> 2=1... loop. + record.tuple.seq = 2; // Make the record seq:2 to get the seq:2 audio. + record.refTuple = MessageTuple(); + delete reader; + return true; + } + } + if (g_sci->getGameId() == GID_LAURABOW2 && !g_sci->isCD() && stack.getModule() == 1885 && t.noun == 1 && t.verb == 6 && t.cond == 16 && t.seq == 4 && (g_sci->getEngineState()->currentRoomNumber() == 350 || |