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

sev- sev at scummvm.org
Thu Aug 13 11:49:59 UTC 2020


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

Summary:
1d6984ab4f DIRECTOR: LINGO: Always display patched scripts
f763dbd6c5 DIRECTOR: Added comment sections to castmember.cpp
f8def75cdc DIRECTOR: Do not warn on empty unused scripts


Commit: 1d6984ab4f429b4aceace98426583ab9f727601d
    https://github.com/scummvm/scummvm/commit/1d6984ab4f429b4aceace98426583ab9f727601d
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-08-13T13:25:07+02:00

Commit Message:
DIRECTOR: LINGO: Always display patched scripts

Changed paths:
    engines/director/lingo/lingo-patcher.cpp


diff --git a/engines/director/lingo/lingo-patcher.cpp b/engines/director/lingo/lingo-patcher.cpp
index b84520ba47..ad9703b548 100644
--- a/engines/director/lingo/lingo-patcher.cpp
+++ b/engines/director/lingo/lingo-patcher.cpp
@@ -197,7 +197,7 @@ Common::String Lingo::patchLingoCode(Common::String &line, LingoArchive *archive
 		}
 
 		// Now everything matched
-		debugC(1, kDebugParse | kDebugPreprocess, "Lingo::patchLingoCode(): Applied a patch for '%s', '%s' %s:%d @ %d. \"%s\" -> \"%s\"",
+		warning("Lingo::patchLingoCode(): Applied a patch for '%s', '%s' %s:%d @ %d. \"%s\" -> \"%s\"",
 				patch->gameId, patch->movie, scriptType2str(type), id, linenum,
 				patch->orig, patch->replace);
 		return patch->replace;


Commit: f763dbd6c5cca983e2307c373cc65d8d03ce2a73
    https://github.com/scummvm/scummvm/commit/f763dbd6c5cca983e2307c373cc65d8d03ce2a73
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-08-13T13:29:31+02:00

Commit Message:
DIRECTOR: Added comment sections to castmember.cpp

Changed paths:
    engines/director/castmember.cpp


diff --git a/engines/director/castmember.cpp b/engines/director/castmember.cpp
index 9eeddf58b6..439da4c3f5 100644
--- a/engines/director/castmember.cpp
+++ b/engines/director/castmember.cpp
@@ -47,6 +47,11 @@ CastMember::CastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndi
 	_modified = true;
 }
 
+
+/////////////////////////////////////
+// Bitmap
+/////////////////////////////////////
+
 BitmapCastMember::BitmapCastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint32 castTag, uint16 version, uint8 flags1)
 		: CastMember(cast, castId, stream) {
 	_type = kCastBitmap;
@@ -233,6 +238,11 @@ Graphics::Surface *BitmapCastMember::getMatte() {
 	return _matte ? _matte->getMask() : nullptr;
 }
 
+
+/////////////////////////////////////
+// DigitalVideo
+/////////////////////////////////////
+
 DigitalVideoCastMember::DigitalVideoCastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint16 version)
 		: CastMember(cast, castId, stream) {
 	_type = kCastDigitalVideo;
@@ -370,6 +380,10 @@ void DigitalVideoCastMember::setFrameRate(int rate) {
 }
 
 
+/////////////////////////////////////
+// Sound
+/////////////////////////////////////
+
 SoundCastMember::SoundCastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint16 version)
 		: CastMember(cast, castId, stream) {
 	_type = kCastSound;
@@ -377,6 +391,11 @@ SoundCastMember::SoundCastMember(Cast *cast, uint16 castId, Common::SeekableRead
 	_looping = 0;
 }
 
+
+/////////////////////////////////////
+// Text
+/////////////////////////////////////
+
 TextCastMember::TextCastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint16 version, uint8 flags1, bool asButton)
 		: CastMember(cast, castId, stream) {
 	_type = kCastText;
@@ -618,6 +637,11 @@ void TextCastMember::updateFromWidget(Graphics::MacWidget *widget) {
 	}
 }
 
+
+/////////////////////////////////////
+// Shape
+/////////////////////////////////////
+
 ShapeCastMember::ShapeCastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint16 version)
 		: CastMember(cast, castId, stream) {
 	_type = kCastShape;
@@ -672,6 +696,11 @@ ShapeCastMember::ShapeCastMember(Cast *cast, uint16 castId, Common::SeekableRead
 		_initialRect.debugPrint(0, "ShapeCastMember: rect:");
 }
 
+
+/////////////////////////////////////
+// Script
+/////////////////////////////////////
+
 ScriptCastMember::ScriptCastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint16 version)
 		: CastMember(cast, castId, stream) {
 	_type = kCastLingoScript;
@@ -708,6 +737,11 @@ ScriptCastMember::ScriptCastMember(Cast *cast, uint16 castId, Common::SeekableRe
 	}
 }
 
+
+/////////////////////////////////////
+// RTE
+/////////////////////////////////////
+
 RTECastMember::RTECastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint16 version)
 		: TextCastMember(cast, castId, stream, version) {
 
@@ -728,6 +762,11 @@ void RTECastMember::loadChunks() {
 #endif
 }
 
+
+/////////////////////////////////////
+// Palette
+/////////////////////////////////////
+
 PaletteCastMember::PaletteCastMember(Cast *cast, uint16 castId, Common::SeekableReadStreamEndian &stream, uint16 version)
 	: CastMember(cast, castId, stream) {
 	_type = kCastPalette;


Commit: f8def75cdcf9abacb183dd92695818316c886812
    https://github.com/scummvm/scummvm/commit/f8def75cdcf9abacb183dd92695818316c886812
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-08-13T13:35:12+02:00

Commit Message:
DIRECTOR: Do not warn on empty unused scripts

Changed paths:
    engines/director/score.cpp


diff --git a/engines/director/score.cpp b/engines/director/score.cpp
index c8d6328218..4b7986b7d9 100644
--- a/engines/director/score.cpp
+++ b/engines/director/score.cpp
@@ -320,7 +320,7 @@ void Score::update() {
 			}
 			return;
 		}
-		
+
 		if (g_system->getMillis() < _nextFrameTime && !_nextFrame)
 			return;
 	}
@@ -866,7 +866,17 @@ void Score::loadActions(Common::SeekableReadStreamEndian &stream) {
 
 	for (j = _actions.begin(); j != _actions.end(); ++j) {
 		if (!scriptRefs[j->_key]) {
-			warning("Action id %d is not referenced, the code is:\n-----\n%s\n------", j->_key, j->_value.c_str());
+			// Check if it is empty
+			bool empty = true;
+			for (const char *ptr = j->_value.c_str(); *ptr; ptr++)
+				if (*ptr != ' ' || *ptr != '\t' || *ptr != '\n' || *ptr != '\xc2' || *ptr != '-') {
+					empty = false;
+					break;
+				}
+
+			if (!empty)
+				warning("Action id %d is not referenced, the code is:\n-----\n%s\n------", j->_key, j->_value.c_str());
+
 			continue;
 		}
 		if (!j->_value.empty()) {




More information about the Scummvm-git-logs mailing list