summaryrefslogtreecommitdiff
path: root/src/world.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/world.c')
-rw-r--r--src/world.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/world.c b/src/world.c
index a24c7a6..a0f25fc 100644
--- a/src/world.c
+++ b/src/world.c
@@ -105,8 +105,8 @@ world_get(int x, int y)
const int i = x / cfg.tile_width + (y / cfg.tile_height) * cfg.cell_width;
with (cell, g_world.cells[wx + wy * g_world.width])
- return cell->data[i] ? (cell->data[i] - 1) : 0;
- return 0; // oob tile
+ return cell->data[i] - 1;
+ return -1; // oob tile
}
int2