mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-30 18:25:16 +01:00
fix part of #2747: mistake in map coordinate clamping for set ownership
This commit is contained in:
@@ -1751,7 +1751,7 @@ money32 map_set_land_ownership(uint8 flags, sint16 x1, sint16 y1, sint16 x2, sin
|
||||
|
||||
// Clamp to maximum addressable element to prevent long loop spamming the log
|
||||
x1 = clamp(0, x1, RCT2_GLOBAL(RCT2_ADDRESS_MAP_SIZE_UNITS, sint16));
|
||||
y1 = clamp(0, x1, RCT2_GLOBAL(RCT2_ADDRESS_MAP_SIZE_UNITS, sint16));
|
||||
y1 = clamp(0, y1, RCT2_GLOBAL(RCT2_ADDRESS_MAP_SIZE_UNITS, sint16));
|
||||
x2 = min(x2, RCT2_GLOBAL(RCT2_ADDRESS_MAP_SIZE_UNITS, sint16));
|
||||
y2 = min(y2, RCT2_GLOBAL(RCT2_ADDRESS_MAP_SIZE_UNITS, sint16));
|
||||
for (sint16 y = y1; y <= y2; y += 32) {
|
||||
|
||||
Reference in New Issue
Block a user