[Scummvm-cvs-logs] scummvm master -> 62d0fed9a766f5177af0ce0964420d8a392a0bd9

bluegr bluegr at gmail.com
Fri Jul 3 23:44:06 CEST 2015


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:
7a7c2ad61e SHERLOCK: Use IS_ROSE_TATTOO / IS_SERRATED_SCALPEL in more places
62d0fed9a7 SHERLOCK: SS: Remove leftover code


Commit: 7a7c2ad61ea461c5c7185e5595cdacb2c9cde021
    https://github.com/scummvm/scummvm/commit/7a7c2ad61ea461c5c7185e5595cdacb2c9cde021
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2015-07-04T00:42:25+03:00

Commit Message:
SHERLOCK: Use IS_ROSE_TATTOO / IS_SERRATED_SCALPEL in more places

Changed paths:
    engines/sherlock/image_file.cpp
    engines/sherlock/resources.cpp
    engines/sherlock/scene.cpp
    engines/sherlock/talk.cpp



diff --git a/engines/sherlock/image_file.cpp b/engines/sherlock/image_file.cpp
index b9d87d4..c202ab3 100644
--- a/engines/sherlock/image_file.cpp
+++ b/engines/sherlock/image_file.cpp
@@ -96,7 +96,7 @@ void ImageFile::load(Common::SeekableReadStream &stream, bool skipPalette, bool
 		byte *data = new byte[frame._size + 4];
 		stream.read(data, frame._size);
 		Common::fill(data + frame._size, data + frame._size + 4, 0);
-		frame.decompressFrame(data, _vm->getGameID() == GType_RoseTattoo);
+		frame.decompressFrame(data, IS_ROSE_TATTOO);
 		delete[] data;
 
 		push_back(frame);
diff --git a/engines/sherlock/resources.cpp b/engines/sherlock/resources.cpp
index 5aea8cc..206d717 100644
--- a/engines/sherlock/resources.cpp
+++ b/engines/sherlock/resources.cpp
@@ -298,7 +298,7 @@ int Resources::resourceIndex() const {
 Common::SeekableReadStream *Resources::decompress(Common::SeekableReadStream &source) {
 	// This variation can't be used by Rose Tattoo, since compressed resources include the input size,
 	// not the output size. Which means their decompression has to be done via passed buffers
-	assert(_vm->getGameID() == GType_SerratedScalpel);
+	assert(IS_SERRATED_SCALPEL);
 
 	uint32 id = source.readUint32BE();
 	assert(id == MKTAG('L', 'Z', 'V', 0x1A));
@@ -308,7 +308,7 @@ Common::SeekableReadStream *Resources::decompress(Common::SeekableReadStream &so
 }
 
 Common::SeekableReadStream *Resources::decompress(Common::SeekableReadStream &source, uint32 outSize) {
-	int inSize = (_vm->getGameID() == GType_RoseTattoo) ? source.readSint32LE() : -1;
+	int inSize = IS_ROSE_TATTOO ? source.readSint32LE() : -1;
 	byte *outBuffer = (byte *)malloc(outSize);
 	Common::MemoryReadStream *outStream = new Common::MemoryReadStream(outBuffer, outSize, DisposeAfterUse::YES);
 
@@ -318,7 +318,7 @@ Common::SeekableReadStream *Resources::decompress(Common::SeekableReadStream &so
 }
 
 void Resources::decompress(Common::SeekableReadStream &source, byte *buffer, uint32 outSize) {
-	int inputSize = (_vm->getGameID() == GType_RoseTattoo) ? source.readSint32LE() : -1;
+	int inputSize = IS_ROSE_TATTOO ? source.readSint32LE() : -1;
 
 	decompressLZ(source, buffer, outSize, inputSize);
 }
diff --git a/engines/sherlock/scene.cpp b/engines/sherlock/scene.cpp
index c948baa..ea761fe 100644
--- a/engines/sherlock/scene.cpp
+++ b/engines/sherlock/scene.cpp
@@ -390,7 +390,7 @@ bool Scene::loadScene(const Common::String &filename) {
 
 				_bgShapes.resize(bgHeader._numStructs);
 				for (int idx = 0; idx < bgHeader._numStructs; ++idx)
-					_bgShapes[idx].load(*infoStream, _vm->getGameID() == GType_RoseTattoo);
+					_bgShapes[idx].load(*infoStream, true);
 
 				if (_compressed)
 					delete infoStream;
diff --git a/engines/sherlock/talk.cpp b/engines/sherlock/talk.cpp
index d7388fc..217b24a 100644
--- a/engines/sherlock/talk.cpp
+++ b/engines/sherlock/talk.cpp
@@ -424,7 +424,7 @@ void Talk::talkTo(const Common::String &filename) {
 	// previous script can continue
 	popStack();
 
-	if (_vm->getGameID() == GType_SerratedScalpel && filename == "Tube59c") {
+	if (IS_SERRATED_SCALPEL && filename == "Tube59c") {
 		// WORKAROUND: Original game bug causes the results of testing the powdery substance
 		// to disappear too quickly. Introduce a delay to allow it to be properly displayed
 		ui._menuCounter = 30;


Commit: 62d0fed9a766f5177af0ce0964420d8a392a0bd9
    https://github.com/scummvm/scummvm/commit/62d0fed9a766f5177af0ce0964420d8a392a0bd9
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2015-07-04T00:42:26+03:00

Commit Message:
SHERLOCK: SS: Remove leftover code

Changed paths:
    engines/sherlock/scalpel/scalpel_map.cpp



diff --git a/engines/sherlock/scalpel/scalpel_map.cpp b/engines/sherlock/scalpel/scalpel_map.cpp
index efb5e80..6da52e6 100644
--- a/engines/sherlock/scalpel/scalpel_map.cpp
+++ b/engines/sherlock/scalpel/scalpel_map.cpp
@@ -90,10 +90,6 @@ void ScalpelMap::loadSequences(int count, const byte *seq) {
 }
 
 void ScalpelMap::loadData() {
-	// TODO: Remove this
-	if (_vm->getGameID() == GType_RoseTattoo)
-		return;
-
 	// Load the list of location names
 	Common::SeekableReadStream *txtStream = _vm->_res->load("chess.txt");
 






More information about the Scummvm-git-logs mailing list