diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2024-04-08 17:05:16 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2024-04-08 19:40:10 +0200 |
commit | 064379bd0bd929f6b87c50f740e9a783b4d9e054 (patch) | |
tree | b717428ace85bde06fff19ac96b11d95787b538f /src/chunk-walls.cpp | |
parent | 4eefaf4e12199c071d2e6ee0d99b46d2e1d45557 (diff) |
a
Diffstat (limited to 'src/chunk-walls.cpp')
-rw-r--r-- | src/chunk-walls.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/chunk-walls.cpp b/src/chunk-walls.cpp index 13f42ead..c1214cb4 100644 --- a/src/chunk-walls.cpp +++ b/src/chunk-walls.cpp @@ -41,11 +41,11 @@ constexpr Quads::quad get_quad(Direction_ D, Group_ G, float depth) constexpr float X = half_tile.x(), Y = half_tile.y(), Z = TILE_SIZE.z(); const bool is_west = D == Wall::Direction_::W; + fm_assert(G < Group_::COUNT); switch (G) { using enum Group_; - default: - fm_abort("invalid wall_atlas group '%d'", (int)G); + case COUNT: std::unreachable(); case wall: if (!is_west) return {{ @@ -107,6 +107,7 @@ constexpr Quads::quad get_quad(Direction_ D, Group_ G, float depth) {-X, -Y, Z }, }}; } + std::unreachable(); } Array<Quads::indexes> make_indexes_() |