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

peterkohaut peterkohaut at users.noreply.github.com
Mon Aug 2 18:59:49 UTC 2021


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:
afa37d775b TINSEL: Added more opcodes for Noir
b22b990173 TINSEL: Fixed rendering for more text messages


Commit: afa37d775bb8c689aa22dbab53734f10846bccde
    https://github.com/scummvm/scummvm/commit/afa37d775bb8c689aa22dbab53734f10846bccde
Author: Peter Kohaut (peter.kohaut at gmail.com)
Date: 2021-08-02T20:58:21+02:00

Commit Message:
TINSEL: Added more opcodes for Noir

Changed paths:
    engines/tinsel/tinlib.cpp


diff --git a/engines/tinsel/tinlib.cpp b/engines/tinsel/tinlib.cpp
index 4939f4b05b..98d784d802 100644
--- a/engines/tinsel/tinlib.cpp
+++ b/engines/tinsel/tinlib.cpp
@@ -153,7 +153,7 @@ enum MASTER_LIB_CODES {
 	TRYPLAYSAMPLE, UNDIMMUSIC, UNHOOKSCENE, UNTAGACTOR, VIBRATE, WAITFRAME, WAITKEY,
 	WAITSCROLL, WAITTIME, WALK, WALKED, WALKEDPOLY, WALKEDTAG, WALKINGACTOR, WALKPOLY,
 	WALKTAG, WALKXPOS, WALKYPOS, WHICHCD, WHICHINVENTORY, ZZZZZZ, DEC3D, DECINVMAIN,
-	ADDNOTEBOOK, ADDINV3, ADDCONV, SET3DTEXTURE, FADEMUSIC, VOICEOVER, HIGHEST_LIBCODE
+	ADDNOTEBOOK, ADDINV3, ADDCONV, SET3DTEXTURE, FADEMUSIC, VOICEOVER, SETVIEW, HIGHEST_LIBCODE
 };
 
 static const MASTER_LIB_CODES DW1DEMO_CODES[] = {
@@ -3391,7 +3391,7 @@ static void TalkOrSay(CORO_PARAM, SPEECH_TYPE speechType, SCNHANDLE hText, int x
 			if ((_ctx->whatSort == IS_SAY) || (_ctx->whatSort == IS_TALK))
 				_vm->_actor->GetActorMidTop(_ctx->actor, &_ctx->x, &_ctx->y);
 
-			if (!TinselV0) {
+			if (!TinselV0 && !TinselV3) {
 				SetTextPal(_vm->_actor->GetActorRGB(_ctx->actor));
 			}
 			if (TinselV2) {
@@ -4428,6 +4428,14 @@ NoirMapping translateNoirLibCode(int libCode, int32 *pp) {
 		pp -= mapping.numArgs - 1;
 		debug(7, "%s(%d, %d, %d)", mapping.name, pp[0], pp[1], pp[2]);
 		break;
+	case 135:
+	case 221:
+	case 222:
+	case 223:
+		mapping = NoirMapping{"SAY", SAY, 2};
+		pp -= mapping.numArgs - 2;
+		debug(7, "%s_%2Xh(%d, %d)", mapping.name, libCode, pp[0], pp[1]);
+		break;
 	case 151:
 		mapping = NoirMapping{"SETSYSTEMREEL", SETSYSTEMREEL, 2};
 		pp -= mapping.numArgs - 1;
@@ -4443,6 +4451,11 @@ NoirMapping translateNoirLibCode(int libCode, int32 *pp) {
 		pp -= mapping.numArgs - 1;
 		debug(7, "%s(%d, 0x%08X)", mapping.name, pp[0], pp[1]);
 		break;
+	case 154:
+		mapping = NoirMapping{"SETVIEW", SETVIEW, 2};
+		pp -= mapping.numArgs - 1;
+		debug(7, "%s(%d, 0x%08X)", mapping.name, pp[0], pp[1]);
+		break;
 	case 156:
 		mapping = NoirMapping{"SHOWACTOR", SHOWACTOR, 1};
 		pp -= mapping.numArgs - 1;
@@ -4514,6 +4527,7 @@ NoirMapping translateNoirLibCode(int libCode, int32 *pp) {
 		pp -= mapping.numArgs - 1;
 		debug(7, "%s(0x%08X)", mapping.name, pp[0]);
 		break;
+	case 111:
 	case 225: // STUBBED
 		mapping = NoirMapping{"PLAYMOVIE", PLAYMOVIE, 1};
 		pp -= mapping.numArgs - 1;
@@ -5642,6 +5656,12 @@ int CallLibraryRoutine(CORO_PARAM, int operand, int32 *pp, const INT_CONTEXT *pi
 		SetTimer(pp[0], pp[1], pp[2], pp[3]);
 		return -4;
 
+	case SETVIEW:
+		// Noir only
+		pp -= 1;
+		warning("TODO: Implement SETVIEW(0x%08X, %i)", pp[0], pp[1]);
+		return -2;
+
 	case SHELL:
 		// DW2 only
 		Shell(pp[0]);


Commit: b22b990173329f81035bae8e3c25eaed3a8fb9f1
    https://github.com/scummvm/scummvm/commit/b22b990173329f81035bae8e3c25eaed3a8fb9f1
Author: Peter Kohaut (peter.kohaut at gmail.com)
Date: 2021-08-02T20:58:22+02:00

Commit Message:
TINSEL: Fixed rendering for more text messages

Changed paths:
    engines/tinsel/graphics.cpp


diff --git a/engines/tinsel/graphics.cpp b/engines/tinsel/graphics.cpp
index e25603e683..8d69003285 100644
--- a/engines/tinsel/graphics.cpp
+++ b/engines/tinsel/graphics.cpp
@@ -1074,7 +1074,7 @@ void DrawObject(DRAWOBJECT *pObj) {
 		return;
 
 	// If writing constant data, don't bother locking the data pointer and reading src details
-	if (((pObj->flags & DMA_CONST) == 0) || (TinselV3 && pObj->flags == 5)) {
+	if (((pObj->flags & DMA_CONST) == 0) || (TinselV3 && ((pObj->flags & 0x05) == 0x05))) {
 		if (TinselV2) {
 			srcPtr = (byte *)_vm->_handle->LockMem(pObj->hBits);
 			pObj->charBase = nullptr;




More information about the Scummvm-git-logs mailing list