[Scummvm-git-logs] scummvm master -> 7a61cdabd032099cff3483b4a6ad8a45fd20b370

dreammaster noreply at scummvm.org
Thu Jan 30 04:44:13 UTC 2025


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:
2aeeb1106f M4: RIDDLE: Fix Twelvetree interrogation, cleanups
7a61cdabd0 M4: RIDDLE: Fix inventory scrolling


Commit: 2aeeb1106fb32c3ad26b93f31e45ba7b01f2e89e
    https://github.com/scummvm/scummvm/commit/2aeeb1106fb32c3ad26b93f31e45ba7b01f2e89e
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2025-01-29T20:12:59-08:00

Commit Message:
M4: RIDDLE: Fix Twelvetree interrogation, cleanups

Changed paths:
    engines/m4/riddle/rooms/section6/room610.cpp
    engines/m4/riddle/rooms/section6/room610.h


diff --git a/engines/m4/riddle/rooms/section6/room610.cpp b/engines/m4/riddle/rooms/section6/room610.cpp
index 1ca5fbb54cd..c41f5340889 100644
--- a/engines/m4/riddle/rooms/section6/room610.cpp
+++ b/engines/m4/riddle/rooms/section6/room610.cpp
@@ -30,10 +30,10 @@ namespace Rooms {
 
 void Room610::init() {
 	if (_G(game).previous_room != KERNEL_RESTORING_GAME) {
-		_val1 = 1;
-		_val2 = 1;
+		_sgMode = 1;
+		_sgShould = 1;
 		_val3 = 0;
-		_val4 = 1;
+		_kShould = 1;
 		_val5 = 1;
 		_val6 = 0;
 	}
@@ -260,13 +260,13 @@ void Room610::daemon() {
 	case 130:
 		sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 1, 1, 200,
 			_sgSlapsTt2, 1, 1, 1);
-		_val1 = 1;
-		_val2 = 0;
+		_sgMode = 1;
+		_sgShould = 0;
 		_val3 = 0;
 		sendWSMessage_10000(1, _k, _k00, 50, 50, 400, _k00, 50, 60, 4);
 		sendWSMessage_190000(_k, 11);
 		sendWSMessage_1a0000(_k, 11);
-		_val4 = 0;
+		_kShould = 0;
 		_val5 = 1;
 		_val6 = 0;
 		_flag2 = 1;
@@ -279,14 +279,14 @@ void Room610::daemon() {
 		break;
 
 	case 201:
-		switch (_val1) {
+		switch (_sgMode) {
 		case 1:
-			switch (_val2) {
+			switch (_sgShould) {
 			case 0:
 				if (imath_ranged_rand(1, 40) == 1) {
 					sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 1, 46, 200,
 						_sgSlapsTt2, 46, 46, 0);
-					_val1 = 2;
+					_sgMode = 2;
 				} else {
 					sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 1, 1, 200,
 						_sgSlapsTt2, 1, 1, 0);
@@ -301,7 +301,7 @@ void Room610::daemon() {
 			case 3:
 				sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 1, 46, 200,
 					_sgSlapsTt2, 46, 46, 0);
-				_val1 = 2;
+				_sgMode = 2;
 				break;
 
 			case 4:
@@ -315,12 +315,12 @@ void Room610::daemon() {
 			break;
 
 		case 2:
-			switch (_val2) {
+			switch (_sgShould) {
 			case 0:
 				if (imath_ranged_rand(1, 40) == 1) {
 					sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 46, 1, 200,
 						_sgSlapsTt2, 1, 1, 0);
-					_val1 = 1;
+					_sgMode = 1;
 				} else {
 					sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 46, 46, 200,
 						_sgSlapsTt2, 46, 46, 0);
@@ -335,14 +335,14 @@ void Room610::daemon() {
 			case 3:
 				sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 47, 48, 202,
 					_sgSlapsTt2, 48, 48, 0);
-				_val1 = 1;
-				_val2 = 0;
+				_sgMode = 1;
+				_sgShould = 0;
 				break;
 
 			default:
 				sendWSMessage_10000(1, _sgTt, _sgSlapsTt2, 47, 48, 202,
 					_sgSlapsTt2, 48, 48, 0);
-				_val1 = 1;
+				_sgMode = 1;
 				break;
 			}
 			break;
@@ -365,7 +365,7 @@ void Room610::daemon() {
 		break;
 
 	case 401:
-		switch (_val4) {
+		switch (_kShould) {
 		case 0:
 			sendWSMessage_10000(1, _k, _k00, 54, 54, 400, _k00, 54, 54, 0);
 			break;
@@ -519,7 +519,7 @@ void Room610::triggerMachineByHashCallback610(frac16 myMessage, machine *sender)
 	int trigger = myMessage >> 16;
 
 	if (trigger >= 0)
-		kernel_trigger_dispatchx(trigger);
+		kernel_trigger_dispatchx(myMessage);
 }
 
 void Room610::setup() {
@@ -528,10 +528,10 @@ void Room610::setup() {
 	sendWSMessage_10000(1, _k, _k00, 50, 50, 400, _k00, 50, 60, 4);
 	sendWSMessage_190000(_k, 11);
 	sendWSMessage_1a0000(_k, 11);
-	_val1 = 1;
-	_val2 = 0;
+	_sgMode = 1;
+	_sgShould = 0;
 	_val3 = 0;
-	_val4 = 0;
+	_kShould = 0;
 	_val5 = 1;
 	_val6 = 0;
 }
@@ -543,7 +543,7 @@ void Room610::talkKuangShenGuo() {
 		digi_stop(2);
 		player_set_commands_allowed(false);
 		_val5 = 2;
-		_val2 = 4;
+		_sgShould = 4;
 		digi_play("610r12", 1, 255, 1);
 		break;
 
@@ -589,7 +589,7 @@ void Room610::talkSamantha() {
 		digi_stop(2);
 		player_set_commands_allowed(false);
 		_val5 = 2;
-		_val2 = 4;
+		_sgShould = 4;
 		digi_play("610r14", 1, 255, 1);
 		break;
 
@@ -633,7 +633,7 @@ bool Room610::useHorn() {
 
 	if (_G(kernel).trigger == 5) {
 		_val5 = 2;
-		_val2 = 4;
+		_sgShould = 4;
 	}
 
 	// Original never exits parser even when this code is called
@@ -723,7 +723,7 @@ void Room610::daemonPreprocess() {
 		break;
 
 	case 137:
-		_val2 = 3;
+		_sgShould = 3;
 		break;
 
 	default:
@@ -746,7 +746,7 @@ void Room610::daemonPostprocess() {
 			ws_walk(202, 244, nullptr, 666, 11);
 			_flag1 = true;
 			_val5 = 2;
-			_val2 = 4;
+			_sgShould = 4;
 		}
 	}
 }
diff --git a/engines/m4/riddle/rooms/section6/room610.h b/engines/m4/riddle/rooms/section6/room610.h
index b3ae4da494d..1f16fec95d2 100644
--- a/engines/m4/riddle/rooms/section6/room610.h
+++ b/engines/m4/riddle/rooms/section6/room610.h
@@ -41,10 +41,10 @@ private:
 	machine *_k = nullptr;
 	machine *_sgTt = nullptr;
 	machine *_pu01 = nullptr;
-	int _val1 = 0;
-	int _val2 = 0;
+	int _sgMode = 0;
+	int _sgShould = 0;
 	int _val3 = 0;
-	int _val4 = 0;
+	int _kShould = 0;
 	int _val5 = 0;
 	int _val6 = 0;
 	int _val7 = 0;


Commit: 7a61cdabd032099cff3483b4a6ad8a45fd20b370
    https://github.com/scummvm/scummvm/commit/7a61cdabd032099cff3483b4a6ad8a45fd20b370
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2025-01-29T20:44:03-08:00

Commit Message:
M4: RIDDLE: Fix inventory scrolling

Changed paths:
    engines/m4/riddle/gui/inventory.cpp


diff --git a/engines/m4/riddle/gui/inventory.cpp b/engines/m4/riddle/gui/inventory.cpp
index d370cdb8bbc..1d8a414a27a 100644
--- a/engines/m4/riddle/gui/inventory.cpp
+++ b/engines/m4/riddle/gui/inventory.cpp
@@ -61,7 +61,7 @@ Inventory::Inventory(const RectClass &r, int32 sprite, int16 cells_h, int16 cell
 	_right_arrow_visible = false;
 
 	_btnScrollLeft = new ButtonClass(RectClass(178, -8, 198, 101), "scroll left", 9, 129, 130, 131, INTERFACE_SPRITES);
-	_btnScrollRight = new ButtonClass(RectClass(551, -8, 571, 101), "scroll right", 9, 133, 134, 135, INTERFACE_SPRITES);
+	_btnScrollRight = new ButtonClass(RectClass(551, -8, 571, 101), "scroll right", 10, 133, 134, 135, INTERFACE_SPRITES);
 	refresh_left_arrow();
 	refresh_right_arrow();
 }




More information about the Scummvm-git-logs mailing list