Started work on using tiled
This commit is contained in:
@ -32,7 +32,7 @@ target_sources(${DAWN_TARGET_NAME}
|
||||
)
|
||||
|
||||
# Assets
|
||||
tool_copy(testmap testmap.json)
|
||||
tool_map(testmap map/testmap.tmx)
|
||||
tool_copy(en en.json)
|
||||
|
||||
add_dependencies(${DAWN_TARGET_NAME} dawnassets)
|
||||
|
@ -37,6 +37,7 @@ char_t symbolGetCharByEntity(const entity_t *ent) {
|
||||
char_t symbolGetCharByTile(const tile_t tile) {
|
||||
switch(tile) {
|
||||
case TILE_NULL:
|
||||
case TILE_WALKABLE_NULL:
|
||||
return ' ';
|
||||
|
||||
case TILE_GRASS:
|
||||
@ -85,6 +86,7 @@ uint8_t symbolGetColorByEntity(const entity_t *ent) {
|
||||
uint8_t symbolGetColorByTile(const tile_t tile) {
|
||||
switch(tile) {
|
||||
case TILE_NULL:
|
||||
case TILE_WALKABLE_NULL:
|
||||
return COLOR_BLACK;
|
||||
|
||||
case TILE_GRASS:
|
||||
|
@ -9,7 +9,7 @@
|
||||
#include "assert/assert.h"
|
||||
|
||||
const char_t * MAP_LIST_PATHS[] = {
|
||||
"testmap.json"
|
||||
"testmap.map"
|
||||
};
|
||||
|
||||
const int32_t MAP_LIST_COUNT = sizeof(MAP_LIST_PATHS) / sizeof(char_t*);
|
||||
|
@ -14,7 +14,8 @@ typedef enum {
|
||||
TILE_WATER = 2,
|
||||
// TILE_DOOR = 3,
|
||||
TILE_BUILDING_WALL = 4,
|
||||
TILE_ROOF = 5
|
||||
TILE_ROOF = 5,
|
||||
TILE_WALKABLE_NULL = 6,
|
||||
} tile_t;
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user