summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/chunk.cpp2
-rw-r--r--src/chunk.hpp8
2 files changed, 7 insertions, 3 deletions
diff --git a/src/chunk.cpp b/src/chunk.cpp
index 6a325125..55afe1b9 100644
--- a/src/chunk.cpp
+++ b/src/chunk.cpp
@@ -147,11 +147,13 @@ chunk& chunk::operator=(chunk&&) noexcept = default;
void chunk::mark_ground_modified() noexcept { _ground_modified = true; }
void chunk::mark_walls_modified() noexcept { _walls_modified = true; }
+void chunk::mark_scenery_modified() noexcept { _scenery_modified = true; }
void chunk::mark_modified() noexcept
{
mark_ground_modified();
mark_walls_modified();
+ mark_scenery_modified();
}
} // namespace floormat
diff --git a/src/chunk.hpp b/src/chunk.hpp
index 16533e5a..9acd5f12 100644
--- a/src/chunk.hpp
+++ b/src/chunk.hpp
@@ -41,6 +41,7 @@ struct chunk final
void mark_ground_modified() noexcept;
void mark_walls_modified() noexcept;
+ void mark_scenery_modified() noexcept;
void mark_modified() noexcept;
struct ground_mesh_tuple final {
@@ -69,9 +70,10 @@ private:
std::array<scenery, TILE_COUNT> _scenery_variants = {};
std::bitset<TILE_COUNT*2> _passability = {};
GL::Mesh ground_mesh{NoCreate}, wall_mesh{NoCreate};
- mutable bool _maybe_empty : 1 = true,
- _ground_modified : 1 = true,
- _walls_modified : 1 = true;
+ mutable bool _maybe_empty : 1 = true,
+ _ground_modified : 1 = true,
+ _walls_modified : 1 = true,
+ _scenery_modified : 1 = true;
};
} // namespace floormat