X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fworld%2FChunkStore.hpp;h=a0fd0f93686b07b68a934160c658cc4390828e76;hb=7bd3601fafbecae415bd96fc24404b21338cd7a4;hp=12debef87b8f4997460959c40d5b71f668f91d22;hpb=4727825186798902f68df5b99a6a32f0ef618454;p=blank.git diff --git a/src/world/ChunkStore.hpp b/src/world/ChunkStore.hpp index 12debef..a0fd0f9 100644 --- a/src/world/ChunkStore.hpp +++ b/src/world/ChunkStore.hpp @@ -13,7 +13,7 @@ class ChunkIndex; class ChunkStore { public: - ChunkStore(const BlockTypeRegistry &); + explicit ChunkStore(const BlockTypeRegistry &); ~ChunkStore(); ChunkStore(const ChunkStore &) = delete; @@ -26,7 +26,8 @@ public: ChunkIndex *ClosestIndex(const ExactLocation::Coarse &pos); /// returns nullptr if given position is not loaded - Chunk *Get(const ExactLocation::Coarse &); + Chunk *Get(const ExactLocation::Coarse &) noexcept; + const Chunk *Get(const ExactLocation::Coarse &) const noexcept; /// returns nullptr if given position is not indexed Chunk *Allocate(const ExactLocation::Coarse &);