summaryrefslogtreecommitdiff
path: root/include/map.h
diff options
context:
space:
mode:
authorAnonymousRandomPerson <chenghanngan.us@gmail.com>2021-12-14 23:36:22 -0500
committerAnonymousRandomPerson <chenghanngan.us@gmail.com>2021-12-17 23:38:06 -0500
commitb1fc911965c584f5af6522849162527f41461b7c (patch)
tree6466b915b8223015e3c7ebad7e73d4b6755c4be2 /include/map.h
parentda8fcb2ac85554bb099dff69f1d0ec1226156afd (diff)
Decomped InSameRoom_2()
Diffstat (limited to 'include/map.h')
-rw-r--r--include/map.h23
1 files changed, 8 insertions, 15 deletions
diff --git a/include/map.h b/include/map.h
index 7863b46..2989c6c 100644
--- a/include/map.h
+++ b/include/map.h
@@ -2,8 +2,10 @@
#define GUARD_MAP_H
#include "dungeon_entity.h"
+#include "position.h"
#define MAX_ROOM_COUNT 24 // Empirical max, not sure if the code supports any more.
+#define CORRIDOR_ROOM_INDEX 0xFF
struct MapTile
{
@@ -25,25 +27,16 @@ struct MapTile
/* 0x14 */ struct DungeonEntity *mapObject; // Item or trap on the tile.
};
-struct Position
-{
- s16 x;
- s16 y;
-};
-
-struct Position32
-{
- s32 x;
- s32 y;
-};
-
struct MapRoom
{
u8 fill0[0x2 - 0x0];
// All coordinates are inclusive.
- /* 0x2 */ struct Position start;
- /* 0x6 */ struct Position end;
- u8 fillA[0x1C - 0xA];
+ // These are not aligned properly to use the Position struct.
+ /* 0x2 */ s16 startX;
+ /* 0x4 */ s16 startY;
+ /* 0x6 */ s16 endX;
+ /* 0x8 */ s16 endY;
+ u8 fillA[0x1A - 0xA];
};
enum TileType