summaryrefslogtreecommitdiff
path: root/src/data
diff options
context:
space:
mode:
Diffstat (limited to 'src/data')
-rw-r--r--src/data/decoration/tilemaps.h171
-rw-r--r--src/data/decoration/tiles.h2
2 files changed, 92 insertions, 81 deletions
diff --git a/src/data/decoration/tilemaps.h b/src/data/decoration/tilemaps.h
index 12fe31dc0..eebb3acb2 100644
--- a/src/data/decoration/tilemaps.h
+++ b/src/data/decoration/tilemaps.h
@@ -1,37 +1,37 @@
-const u8 Unknown_085A6FB0[] = {
+static const u8 sDecorTilemap_1x1_Tiles[] = {
0x00, 0x01, 0x02, 0x03
};
-const u8 Unknown_085A6FB4[] = {
+static const u8 sDecorTilemap_3x1_Tiles[] = {
0x00, 0x01, 0x02, 0x03, 0x04, 0x05,
0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d
};
-const u8 Unknown_085A6FC0[] = {
+static const u8 sDecorTilemap_2x2_Tiles[] = {
0x00, 0x01, 0x02, 0x03,
0x04, 0x05, 0x06, 0x07,
0x08, 0x09, 0x0a, 0x0b,
0x0c, 0x0d, 0x0e, 0x0f
};
-const u8 Unknown_085A6FD0[] = {
+static const u8 sDecorTilemap_1x3_Tiles[] = {
0x00, 0x01, 0x04, 0x05,
0x08, 0x09, 0x0c, 0x0d,
0x10, 0x11, 0x14, 0x15
};
-const u8 Unknown_085A6FDC[] = {
+static const u8 sDecorTilemap_2x1_Tiles[] = {
0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07
};
-const u8 Unknown_085A6FE4[] = {
+static const u8 sDecorTilemap_4x2_Tiles[] = {
0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f,
0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17,
0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f
};
-const u8 Unknown_085A7004[] = {
+static const u8 sDecorTilemap_3x3_Tiles[] = {
0x00, 0x01, 0x02, 0x03, 0x04, 0x05,
0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d,
0x10, 0x11, 0x12, 0x13, 0x14, 0x15,
@@ -40,60 +40,60 @@ const u8 Unknown_085A7004[] = {
0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d
};
-const u8 Unknown_085A7028[] = {
+static const u8 sDecorTilemap_3x2_Tiles[] = {
0x00, 0x01, 0x02, 0x03, 0x04, 0x05,
0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d,
0x10, 0x11, 0x12, 0x13, 0x14, 0x15,
0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d
};
-const u8 Unknown_085A7040[] = {
+static const u8 sDecorTilemap_1x1_Y[] = {
0x00, 0x00, 0x00, 0x00
};
-const u8 Unknown_085A7044[] = {
+static const u8 sDecorTilemap_2x1_Y[] = {
0x00, 0x00, 0x01, 0x01,
0x00, 0x00, 0x01, 0x01
};
-const u8 Unknown_085A704C[] = {
+static const u8 sDecorTilemap_3x1_Y[] = {
0x00, 0x00, 0x01, 0x01, 0x02, 0x02,
0x00, 0x00, 0x01, 0x01, 0x02, 0x02
};
-const u8 Unknown_085A7058[] = {
+static const u8 sDecorTilemap_4x2_Y[] = {
0x00, 0x00, 0x01, 0x01, 0x02, 0x02, 0x03, 0x03,
0x00, 0x00, 0x01, 0x01, 0x02, 0x02, 0x03, 0x03,
0x04, 0x04, 0x05, 0x05, 0x06, 0x06, 0x07, 0x07,
0x04, 0x04, 0x05, 0x05, 0x06, 0x06, 0x07, 0x07
};
-const u8 Unknown_085A7078[] = {
+static const u8 sDecorTilemap_2x2_Y[] = {
0x00, 0x00, 0x01, 0x01,
0x00, 0x00, 0x01, 0x01,
0x02, 0x02, 0x03, 0x03,
0x02, 0x02, 0x03, 0x03
};
-const u8 Unknown_085A7088[] = {
+static const u8 sDecorTilemap_1x2_Y[] = {
0x00, 0x00, 0x00, 0x00,
0x01, 0x01, 0x01, 0x01
};
-const u8 Unknown_085A7090[] = {
+static const u8 sDecorTilemap_1x3_Y[] = {
0x00, 0x00, 0x00, 0x00,
0x01, 0x01, 0x01, 0x01,
0x02, 0x02, 0x02, 0x02
};
-const u8 Unknown_085A709C[] = {
+static const u8 sDecorTilemap_2x4_Y[] = {
0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x01, 0x01,
0x02, 0x02, 0x03, 0x03, 0x02, 0x02, 0x03, 0x03,
0x04, 0x04, 0x05, 0x05, 0x04, 0x04, 0x05, 0x05,
0x06, 0x06, 0x07, 0x07, 0x06, 0x06, 0x07, 0x07
};
-const u8 Unknown_085A70BC[] = {
+static const u8 sDecorTilemap_3x3_Y[] = {
0x00, 0x00, 0x01, 0x01, 0x02, 0x02,
0x00, 0x00, 0x01, 0x01, 0x02, 0x02,
0x03, 0x03, 0x04, 0x04, 0x05, 0x05,
@@ -102,60 +102,60 @@ const u8 Unknown_085A70BC[] = {
0x06, 0x06, 0x07, 0x07, 0x08, 0x08
};
-const u8 Unknown_085A70E0[] = {
+static const u8 sDecorTilemap_3x2_Y[] = {
0x00, 0x00, 0x01, 0x01, 0x02, 0x02,
0x00, 0x00, 0x01, 0x01, 0x02, 0x02,
0x03, 0x03, 0x04, 0x04, 0x05, 0x05,
0x03, 0x03, 0x04, 0x04, 0x05, 0x05
};
-const u8 Unknown_085A70F8[] = {
+static const u8 sDecorTilemap_1x1_X[] = {
0x04, 0x05, 0x06, 0x07
};
-const u8 Unknown_085A70FC[] = {
+static const u8 sDecorTilemap_2x1_X[] = {
0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07
};
-const u8 Unknown_085A7104[] = {
+static const u8 sDecorTilemap_3x1_X[] = {
0x04, 0x05, 0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07, 0x06, 0x07
};
-const u8 Unknown_085A7110[] = {
+static const u8 sDecorTilemap_4x2_X[] = {
0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07,
0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07, 0x06, 0x07, 0x06, 0x07
};
-const u8 Unknown_085A7130[] = {
+static const u8 sDecorTilemap_2x2_X[] = {
0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07,
0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07
};
-const u8 Unknown_085A7140[] = {
+static const u8 sDecorTilemap_1x2_X[] = {
0x04, 0x05, 0x06, 0x07,
0x04, 0x05, 0x06, 0x07
};
-const u8 Unknown_085A7148[] = {
+static const u8 sDecorTilemap_1x3_X[] = {
0x04, 0x05, 0x06, 0x07,
0x04, 0x05, 0x06, 0x07,
0x04, 0x05, 0x06, 0x07
};
-const u8 Unknown_085A7154[] = {
+static const u8 sDecorTilemap_2x4_X[] = {
0x04, 0x05, 0x04, 0x05, 0x06, 0x07, 0x06, 0x07,
0x04, 0x05, 0x04, 0x05, 0x06, 0x07, 0x06, 0x07,
0x04, 0x05, 0x04, 0x05, 0x06, 0x07, 0x06, 0x07,
0x04, 0x05, 0x04, 0x05, 0x06, 0x07, 0x06, 0x07
};
-const u8 Unknown_085A7174[] = {
+static const u8 sDecorTilemap_3x3_X[] = {
0x04, 0x05, 0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07, 0x06, 0x07,
0x04, 0x05, 0x04, 0x05, 0x04, 0x05,
@@ -164,67 +164,78 @@ const u8 Unknown_085A7174[] = {
0x06, 0x07, 0x06, 0x07, 0x06, 0x07
};
-const u8 Unknown_085A7198[] = {
+static const u8 sDecorTilemap_3x2_X[] = {
0x04, 0x05, 0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07, 0x06, 0x07,
0x04, 0x05, 0x04, 0x05, 0x04, 0x05,
0x06, 0x07, 0x06, 0x07, 0x06, 0x07
};
-const struct {
+#define DECORSIZE(width, height)((width) * (height) * 4)
+
+static const struct {
const u8 *tiles;
const u8 *y;
const u8 *x;
u8 size;
-} gUnknown_085A71B0[] = {
- {
- Unknown_085A6FB0,
- Unknown_085A7040,
- Unknown_085A70F8,
- 0x04
- }, {
- Unknown_085A6FDC,
- Unknown_085A7044,
- Unknown_085A70FC,
- 0x08
- }, {
- Unknown_085A6FB4,
- Unknown_085A704C,
- Unknown_085A7104,
- 0x0c
- }, {
- Unknown_085A6FE4,
- Unknown_085A7058,
- Unknown_085A7110,
- 0x20
- }, {
- Unknown_085A6FC0,
- Unknown_085A7078,
- Unknown_085A7130,
- 0x10
- }, {
- Unknown_085A6FDC,
- Unknown_085A7088,
- Unknown_085A7140,
- 0x08
- }, {
- Unknown_085A6FD0,
- Unknown_085A7090,
- Unknown_085A7148,
- 0x0c
- }, {
- Unknown_085A6FE4,
- Unknown_085A709C,
- Unknown_085A7154,
- 0x20
- }, {
- Unknown_085A7004,
- Unknown_085A70BC,
- Unknown_085A7174,
- 0x24
- }, {
- Unknown_085A7028,
- Unknown_085A70E0,
- Unknown_085A7198,
- 0x18
+} sDecorTilemaps[] = {
+ [DECORSHAPE_1x1] = {
+ .tiles = sDecorTilemap_1x1_Tiles,
+ .y = sDecorTilemap_1x1_Y,
+ .x = sDecorTilemap_1x1_X,
+ .size = DECORSIZE(1, 1)
+ },
+ [DECORSHAPE_2x1] = {
+ .tiles = sDecorTilemap_2x1_Tiles,
+ .y = sDecorTilemap_2x1_Y,
+ .x = sDecorTilemap_2x1_X,
+ .size = DECORSIZE(2, 1)
+ },
+ [DECORSHAPE_3x1] = {
+ .tiles = sDecorTilemap_3x1_Tiles,
+ .y = sDecorTilemap_3x1_Y,
+ .x = sDecorTilemap_3x1_X,
+ .size = DECORSIZE(3, 1)
+ },
+ [DECORSHAPE_4x2] = {
+ .tiles = sDecorTilemap_4x2_Tiles,
+ .y = sDecorTilemap_4x2_Y,
+ .x = sDecorTilemap_4x2_X,
+ .size = DECORSIZE(4, 2)
+ },
+ [DECORSHAPE_2x2] = {
+ .tiles = sDecorTilemap_2x2_Tiles,
+ .y = sDecorTilemap_2x2_Y,
+ .x = sDecorTilemap_2x2_X,
+ .size = DECORSIZE(2, 2)
+ },
+ [DECORSHAPE_1x2] = {
+ .tiles = sDecorTilemap_2x1_Tiles,
+ .y = sDecorTilemap_1x2_Y,
+ .x = sDecorTilemap_1x2_X,
+ .size = DECORSIZE(1, 2)
+ },
+ [DECORSHAPE_1x3] = {
+ .tiles = sDecorTilemap_1x3_Tiles,
+ .y = sDecorTilemap_1x3_Y,
+ .x = sDecorTilemap_1x3_X,
+ .size = DECORSIZE(1, 3)
+ },
+ [DECORSHAPE_2x4] = {
+ .tiles = sDecorTilemap_4x2_Tiles,
+ .y = sDecorTilemap_2x4_Y,
+ .x = sDecorTilemap_2x4_X,
+ .size = DECORSIZE(2, 4)
+ },
+ [DECORSHAPE_3x3] = {
+ .tiles = sDecorTilemap_3x3_Tiles,
+ .y = sDecorTilemap_3x3_Y,
+ .x = sDecorTilemap_3x3_X,
+ .size = DECORSIZE(3, 3)
+ },
+ [DECORSHAPE_3x2] = {
+ .tiles = sDecorTilemap_3x2_Tiles,
+ .y = sDecorTilemap_3x2_Y,
+ .x = sDecorTilemap_3x2_X,
+ .size = DECORSIZE(3, 2)
}};
diff --git a/src/data/decoration/tiles.h b/src/data/decoration/tiles.h
index de5c43575..1b25da3d4 100644
--- a/src/data/decoration/tiles.h
+++ b/src/data/decoration/tiles.h
@@ -1,4 +1,4 @@
-#define DECOR_TILE(name) (METATILE_SecretBase_##name - 0x200)
+#define DECOR_TILE(name) (METATILE_SecretBase_##name - NUM_TILES_IN_PRIMARY)
const u16 DecorGfx_SMALL_DESK[] = {
DECOR_TILE(SmallDesk)