X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fworld%2FChunkIndex.hpp;h=eb961a9d3ca236cef4b7dc5a2857ca75fcf95ec8;hb=5a5b12ae26b832dd8493be2d30f97d14aee2268c;hp=1823de72b154359c4635a7a0e4f0d1d55ae6f9db;hpb=4727825186798902f68df5b99a6a32f0ef618454;p=blank.git diff --git a/src/world/ChunkIndex.hpp b/src/world/ChunkIndex.hpp index 1823de7..eb961a9 100644 --- a/src/world/ChunkIndex.hpp +++ b/src/world/ChunkIndex.hpp @@ -47,6 +47,10 @@ public: int Extent() const noexcept { return extent; } + // raw iteration access, may contain nullptrs + std::vector::const_iterator begin() const noexcept { return chunks.begin(); } + std::vector::const_iterator end() const noexcept { return chunks.end(); } + ExactLocation::Coarse CoordsBegin() const noexcept { return base - ExactLocation::Coarse(extent); } ExactLocation::Coarse CoordsEnd() const noexcept { return base + ExactLocation::Coarse(extent + 1); }