diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2023-03-18 16:03:22 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2023-03-18 16:03:22 +0100 |
commit | 6e7e8c4880b86d4477839cb087b34b4282e5516a (patch) | |
tree | fce74f4b8c9dbdec0439d76c5969cfa05ec442f6 /src | |
parent | 47b28035df1ce64d996b949b971ccf40bae2b9c8 (diff) |
src/chunk: more debug code
Diffstat (limited to 'src')
-rw-r--r-- | src/chunk-collision.cpp | 2 | ||||
-rw-r--r-- | src/chunk-render.cpp | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/src/chunk-collision.cpp b/src/chunk-collision.cpp index c228c514..fc7ab92a 100644 --- a/src/chunk-collision.cpp +++ b/src/chunk-collision.cpp @@ -53,6 +53,8 @@ constexpr std::uint64_t make_id(collision_type type, pass_mode p, std::uint64_t void chunk::ensure_passability() noexcept { + fm_assert(_entities_sorted); // not strictly necessary + if (!_pass_modified) return; _pass_modified = false; diff --git a/src/chunk-render.cpp b/src/chunk-render.cpp index 18e6c4cd..b5e14926 100644 --- a/src/chunk-render.cpp +++ b/src/chunk-render.cpp @@ -106,10 +106,11 @@ auto chunk::ensure_wall_mesh() noexcept -> wall_mesh_tuple auto chunk::ensure_scenery_mesh() noexcept -> scenery_mesh_tuple { + fm_assert(_entities_sorted); + if (_scenery_modified) { _scenery_modified = false; - fm_assert(_entities_sorted); const auto count = fm_begin( std::size_t ret = 0; |