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

mduggan noreply at scummvm.org
Wed Nov 15 05:31:50 UTC 2023


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:
85e13c911a ULTIMA8: Slightly improve usecode debug messages
c2c62df742 ULTIMA8: Increase search range in areaSearch by 1px


Commit: 85e13c911ad2765770a83471b0470b7fab864067
    https://github.com/scummvm/scummvm/commit/85e13c911ad2765770a83471b0470b7fab864067
Author: Matthew Duggan (mgithub at guarana.org)
Date: 2023-11-15T16:31:40+11:00

Commit Message:
ULTIMA8: Slightly improve usecode debug messages

Changed paths:
    engines/ultima/ultima8/usecode/uc_machine.cpp


diff --git a/engines/ultima/ultima8/usecode/uc_machine.cpp b/engines/ultima/ultima8/usecode/uc_machine.cpp
index 048cf2d0e9e..b4d6f5c7a04 100644
--- a/engines/ultima/ultima8/usecode/uc_machine.cpp
+++ b/engines/ultima/ultima8/usecode/uc_machine.cpp
@@ -281,7 +281,7 @@ void UCMachine::execProcess(UCProcess *p) {
 			// push sign-extended 8 bit xx onto the stack as 16 bit
 			ui16a = cs->readSByte();
 			p->_stack.push2(ui16a);
-			TRACE_OP("%s\tpush byte\t%04Xh", op_info, ui16a);
+			TRACE_OP("%s\tpush sbyte\t%04Xh", op_info, ui16a);
 			break;
 
 		case 0x0B:
@@ -1471,7 +1471,7 @@ void UCMachine::execProcess(UCProcess *p) {
 				// skip over class name and null terminator
 				name[x] = cs->readByte();
 			}
-			TRACE_OP("%s\tdebug\tline number %d\t\"%s\"", op_info, opcode, ui16a, name);
+			TRACE_OP("%s\tdebug\tline number %d\t\"%s\"", op_info, ui16a, name);
 			debug(10, "name: \"%s\"", name); // Ensures that name variable is used when TRACE_OP is empty
 			break;
 		}


Commit: c2c62df742b138920020c27c0343e68dd8da8e0c
    https://github.com/scummvm/scummvm/commit/c2c62df742b138920020c27c0343e68dd8da8e0c
Author: Matthew Duggan (mgithub at guarana.org)
Date: 2023-11-15T16:31:40+11:00

Commit Message:
ULTIMA8: Increase search range in areaSearch by 1px

The keypad issue in bug #14680 requires a finding an item exactly the range
given from the keypad.

Changed paths:
    engines/ultima/ultima8/world/current_map.cpp


diff --git a/engines/ultima/ultima8/world/current_map.cpp b/engines/ultima/ultima8/world/current_map.cpp
index d683e92bfe5..b209d98e04a 100644
--- a/engines/ultima/ultima8/world/current_map.cpp
+++ b/engines/ultima/ultima8/world/current_map.cpp
@@ -570,7 +570,13 @@ void CurrentMap::areaSearch(UCList *itemlist, const uint8 *loopscript,
 		check->getFootpadWorld(xd, yd, zd);
 	}
 
-	const Box searchrange(x + range, y + range, 0, xd + range * 2, yd + range * 2, INT_MAX_VALUE);
+	//
+	// Original games consider items at <= range to match. Add a pixel
+	// to range to match that behavior (eg, KEYPAD in Crusader : No Remorse
+	// Mission 12 (map 19) at (17118,34878) uses range 6400 and a VALBOX
+	// exactly 6400 from the KEYPAD.
+	//
+	const Box searchrange(x + range, y + range, 0, xd + range * 2 + 1, yd + range * 2 + 1, INT_MAX_VALUE);
 
 	int minx = ((x - xd - range) / _mapChunkSize) - 1;
 	int maxx = ((x + range) / _mapChunkSize) + 1;




More information about the Scummvm-git-logs mailing list