[Scummvm-git-logs] scummvm master -> d58f594755449f6a0402fdf5dba61cfa5edcf58e

sev- sev at scummvm.org
Sun Jul 30 22:10:58 CEST 2017


This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
392d8b44ff SCUMM: MI2 kill tune 107 on start of next, Fixes bug #1410 / Scabb Island
d58f594755 SCUMM: MI2 kill tune 113 on start of next, Fixes bug #1410 / Booty Island


Commit: 392d8b44ff99d08eabe6007b259d26545f085583
    https://github.com/scummvm/scummvm/commit/392d8b44ff99d08eabe6007b259d26545f085583
Author: Ben Castricum (github at bencastricum.nl)
Date: 2017-07-30T22:10:54+02:00

Commit Message:
SCUMM: MI2 kill tune 107 on start of next, Fixes bug #1410 / Scabb Island

Fix the "MI2: Two soundtracks playing at once" bug from the forum.  It's
triggered when the player is moving faster then the scripts expect causing
the "stop tune 117" command be executed before the start of the tune.
Effectily creating a hanging tune 107.
This patch kills the tune when this sitation is detected.

Changed paths:
    engines/scumm/imuse/imuse.cpp


diff --git a/engines/scumm/imuse/imuse.cpp b/engines/scumm/imuse/imuse.cpp
index 8b892f5..78fd821 100644
--- a/engines/scumm/imuse/imuse.cpp
+++ b/engines/scumm/imuse/imuse.cpp
@@ -675,6 +675,27 @@ bool IMuseInternal::startSound_internal(int sound, int offset) {
 	if (_game_id == GID_SAMNMAX && sound == 82 && getSoundStatus_internal(81, false))
 		ImClearTrigger(81, 1);
 
+	// Workaround for monkey2 bug #1410 / Scabb Island
+	//
+	// Tunes involved:
+	// 100 - Captain Dread's map
+	// 101 - Woodtick
+	// 107 - Map of Scabb Island
+	//
+	// If you go from Woodtick to the map of Scabb Island tune 107 is added as
+	// trigger on 101 and 101 moves to an outro and stop (triggering start
+	// of 107). Then at Captain Dread tune 107 is stopped and 100 is started.
+	//
+	// If you go quickly enough, the trigger occurs not at the Scabb Island
+	// map but at Captain Dread causing tune 107 not to be stopped.
+	// So we prevent starting 107 if 100 is already running.
+	if (_game_id == GID_MONKEY2 && (sound == 107) && (getSoundStatus_internal(100, true) == 1))
+		return false;
+
+	// In some cases 107 is running and doesn't get killed at Dread's map
+	if (_game_id == GID_MONKEY2 && (sound == 100) && (getSoundStatus_internal(107, true) == 1))
+		IMuseInternal::stopSound_internal(107);
+
 	player->clear();
 	player->setOffsetNote(offset);
 	return player->startSound(sound, driver);


Commit: d58f594755449f6a0402fdf5dba61cfa5edcf58e
    https://github.com/scummvm/scummvm/commit/d58f594755449f6a0402fdf5dba61cfa5edcf58e
Author: Ben Castricum (github at bencastricum.nl)
Date: 2017-07-30T22:10:54+02:00

Commit Message:
SCUMM: MI2 kill tune 113 on start of next, Fixes bug #1410 / Booty Island

Fix the "MI2: Two soundtracks playing at once" bug from the bug tracker.
It's triggered when the player enters the kiosk for the second time and
leaves before tune 113 is started.

Changed paths:
    engines/scumm/imuse/imuse.cpp


diff --git a/engines/scumm/imuse/imuse.cpp b/engines/scumm/imuse/imuse.cpp
index 78fd821..b7b72ba 100644
--- a/engines/scumm/imuse/imuse.cpp
+++ b/engines/scumm/imuse/imuse.cpp
@@ -696,6 +696,23 @@ bool IMuseInternal::startSound_internal(int sound, int offset) {
 	if (_game_id == GID_MONKEY2 && (sound == 100) && (getSoundStatus_internal(107, true) == 1))
 		IMuseInternal::stopSound_internal(107);
 
+	// Workaround for monkey2 bug #1410 / Booty Island
+	//
+	// Tunes involved
+	// 100 - Captain Dread's map
+	// 113 - Guard Kiosk / Mardi Grass 
+	// 115 - Map of Booty Island / Ville de la Booty
+	// 118 - Ville de la Booty
+	//
+	// When you enter the Guard Kiosk tune 113 is added as trigger on song
+	// 115. Then if you leave, 113 is stopped and 115 is started again.
+	// If you leave quickly enough, the trigger occurs on the map and tune
+	// 113 will not stop.
+	// We kill 113 on entry of one of the other locations (Captain Dread
+	// or Ville de la Booty) because tune 115 is not always started.
+	if (_game_id == GID_MONKEY2 && (sound == 100 || sound == 115 || sound == 118) && (getSoundStatus_internal(113, true) == 1))
+		IMuseInternal::stopSound_internal(113);
+
 	player->clear();
 	player->setOffsetNote(offset);
 	return player->startSound(sound, driver);





More information about the Scummvm-git-logs mailing list