From f17446f3d261e710703ba4d478ddf4294a9ae3cb Mon Sep 17 00:00:00 2001 From: Lukas Krickl Date: Mon, 6 Jan 2025 07:28:06 +0100 Subject: [PATCH] map: Fixed f1 room table size calculation. This was an off-by-one error due to the placement of the start label which included the table length itself. --- src/map.s | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/map.s b/src/map.s index 050e054..623157e 100644 --- a/src/map.s +++ b/src/map.s @@ -1020,13 +1020,14 @@ map_gen_copy_base_room: #include "base_room4.s" ; count of all pointers in base room table -#define F1_ROOM_TABLE_LEN ((f1_room_table_end - f1_room_table) / 2) +#define F1_ROOM_TABLE_LEN ((f1_room_table_end - f1_room_table_start) / 2) ; the first byte of the table is the length of the table ; a table of all base room ptrs ; length must be divisible by 2 f1_room_table: .db F1_ROOM_TABLE_LEN +f1_room_table_start: dw base_room_header dw base_room2_header dw base_room3_header -- 2.30.2