diff options
| author | tslil clingman <> | 2021-09-12 21:40:58 -0400 |
|---|---|---|
| committer | tslil clingman <> | 2021-09-12 21:40:58 -0400 |
| commit | d89f038b7a5eb42dd48d729d8808747d5cbc182b (patch) | |
| tree | 2f726aef25edaf1723e62ec99e19c425afa37cdf /src/level.zig | |
| parent | b674e201cecf38ae719f76c0d159d8cbf00158ed (diff) | |
Walk bob and collision detection
Diffstat (limited to 'src/level.zig')
| -rw-r--r-- | src/level.zig | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/level.zig b/src/level.zig index 610eb7b..1d61a02 100644 --- a/src/level.zig +++ b/src/level.zig @@ -62,8 +62,7 @@ pub const Map = struct { } pub fn lookup(self: Map, x: i32, y: i32) Cell { - // live dangerously, no bounds check - std.debug.assert(x >= 0 and y >= 0); // compiler hint? + // std.debug.assert(x >= 0 and y >= 0); // would this work as a compiler hint? return self.cells.items[@intCast(u32, y) * self.width + @intCast(u32, x)]; } }; |
