aboutsummaryrefslogtreecommitdiff
path: root/src/terrain/inc
diff options
context:
space:
mode:
authorXavier Del Campo Romero <xavi.dcr@tutanota.com>2024-01-27 17:10:35 +0100
committerXavier Del Campo Romero <xavi.dcr@tutanota.com>2024-01-28 04:12:45 +0100
commitdb3ee0d63620bd42f27a6b359f0996df927481dd (patch)
tree3ed8d42e1c0414c5d7fd8d4e2ca96bb19a59b3c6 /src/terrain/inc
parentcd2b58b5619bf33deb99b0765f2d69969c61ed74 (diff)
downloadjancity-db3ee0d63620bd42f27a6b359f0996df927481dd.tar.gz
terrain: Split tile/object rendering
Diffstat (limited to 'src/terrain/inc')
-rw-r--r--src/terrain/inc/terrain.h69
1 files changed, 2 insertions, 67 deletions
diff --git a/src/terrain/inc/terrain.h b/src/terrain/inc/terrain.h
index f6cf37f..7997025 100644
--- a/src/terrain/inc/terrain.h
+++ b/src/terrain/inc/terrain.h
@@ -13,78 +13,12 @@ extern "C"
enum
{
- MAP_TILES = 64,
+ MAP_TILES = 120,
TERRAIN_SZ = 16,
MAP_W = MAP_TILES * TERRAIN_SZ,
MAP_H = MAP_TILES * TERRAIN_SZ
};
-enum terrain_type
-{
- ROOF1_1_NW,
- ROOF1_1_N,
- ROOF1_1_NE,
- ROOF1_2_NW,
- ROOF1_2_NE,
- ROOF1_3_NW,
- ROOF1_3_N,
- ROOF1_3_NE,
- ROOF1_4_N,
-
- ROOF1_1_W,
- ROOF1_1_C,
- ROOF1_1_E,
- ROOF1_2_SW,
- ROOF1_2_SE,
- ROOF1_3_SW,
- ROOF1_3_S,
- ROOF1_3_SE,
- ROOF1_4_C,
-
- ROOF1_1_SW,
- ROOF1_1_S,
- ROOF1_1_SE,
- ROOF1_5_W,
- ROOF1_5_C,
- ROOF1_5_E,
- ROOF1_6,
- ROOF1_4_S,
-
- ROOF2_1_NW,
- ROOF2_1_N,
- ROOF2_1_NE,
- ROOF2_2_NW,
- ROOF2_2_NE,
- ROOF2_3_NW,
- ROOF2_3_N,
- ROOF2_3_NE,
- ROOF2_4_N,
-
- ROOF2_1_W,
- ROOF2_1_C,
- ROOF2_1_E,
- ROOF2_2_SW,
- ROOF2_2_SE,
- ROOF2_3_SW,
- ROOF2_3_S,
- ROOF2_3_SE,
- ROOF2_4_C,
-
- ROOF2_1_SW,
- ROOF2_1_S,
- ROOF2_1_SE,
- ROOF2_5_W,
- ROOF2_5_C,
- ROOF2_5_E,
- ROOF2_6,
- ROOF2_4_S,
-
- ROOF1_START = ROOF1_1_NW,
- ROOF1_END = ROOF1_4_S,
- ROOF2_START = ROOF2_1_NW,
- ROOF2_END = ROOF2_4_S
-};
-
struct terrain_map
{
struct terrain_tile
@@ -102,6 +36,7 @@ int terrain_render(const struct terrain_map *map, const struct camera *cam);
enum
{
SIDEWALK,
+ GRASS,
ROOF1,
ROOF2,
BUILDING1,