+ static constexpr std::size_t BlockSize() noexcept { return offsetof(Chunk, position) - offsetof(Chunk, blocks); }
+
+ bool Generated() const noexcept { return generated; }
+ void SetGenerated() noexcept { generated = true; }
+ bool Lighted() const noexcept { return lighted; }
+ void ScanLights();
+
+ /// check for active blocks, should be called after
+ /// block data was modified by means other than SetBlock()
+ void ScanActive();
+
+ void Ref() noexcept { ++ref_count; }
+ void UnRef() noexcept { --ref_count; }
+ bool Referenced() const noexcept { return ref_count > 0; }