[Scummvm-cvs-logs] scummvm master -> d2c4074fa65106e5e26f66cf9ce79fe6f5214da6

dreammaster dreammaster at scummvm.org
Wed Jul 1 03:19:25 CEST 2015


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

Summary:
d2c4074fa6 SHERLOCK: RT: Fix incorrectly playing sounds when looking at objects


Commit: d2c4074fa65106e5e26f66cf9ce79fe6f5214da6
    https://github.com/scummvm/scummvm/commit/d2c4074fa65106e5e26f66cf9ce79fe6f5214da6
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2015-06-30T21:18:26-04:00

Commit Message:
SHERLOCK: RT: Fix incorrectly playing sounds when looking at objects

Changed paths:
    engines/sherlock/objects.cpp
    engines/sherlock/tattoo/tattoo_user_interface.cpp



diff --git a/engines/sherlock/objects.cpp b/engines/sherlock/objects.cpp
index 97d63c5..0a4b7e9 100644
--- a/engines/sherlock/objects.cpp
+++ b/engines/sherlock/objects.cpp
@@ -979,8 +979,13 @@ void Object::load(Common::SeekableReadStream &s, bool isRoseTattoo) {
 	_aType = (AType)s.readByte();
 	_lookFrames = s.readByte();
 	_seqCounter = s.readByte();
-	_lookPosition.x = s.readUint16LE() * FIXED_INT_MULTIPLIER / 100;
-	_lookPosition.y = (isRoseTattoo ? s.readSint16LE() : s.readByte()) * FIXED_INT_MULTIPLIER;
+	if (isRoseTattoo) {
+		_lookPosition.x = s.readUint16LE() * FIXED_INT_MULTIPLIER;
+		_lookPosition.y = s.readSint16LE() * FIXED_INT_MULTIPLIER;
+	} else {
+		_lookPosition.x = s.readUint16LE() * FIXED_INT_MULTIPLIER / 100;
+		_lookPosition.y = s.readByte() * FIXED_INT_MULTIPLIER;
+	}
 	_lookFacing = s.readByte();
 	_lookcAnim = s.readByte();
 
diff --git a/engines/sherlock/tattoo/tattoo_user_interface.cpp b/engines/sherlock/tattoo/tattoo_user_interface.cpp
index 79a6eaf..7de7845 100644
--- a/engines/sherlock/tattoo/tattoo_user_interface.cpp
+++ b/engines/sherlock/tattoo/tattoo_user_interface.cpp
@@ -108,7 +108,7 @@ void TattooUserInterface::lookAtObject() {
 						name.deleteLastChar();
 
 					// See if this Object Sound List entry matches the object's name
-					if (_bgShape->_name.compareToIgnoreCase(name)) {					
+					if (!_bgShape->_name.compareToIgnoreCase(name)) {					
 						// Move forward to get the sound filename
 						while ((*p == ' ') || (*p == '='))
 							++p;






More information about the Scummvm-git-logs mailing list