X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fworld%2FBlockLookup.hpp;h=214608ef49ce14ca06c1d2de3b69a05133081f67;hb=b94a7dc7daad9ae9be90a39d723e332dae375325;hp=3d7aa0420f442d204311086ac1025e31000697df;hpb=4727825186798902f68df5b99a6a32f0ef618454;p=blank.git diff --git a/src/world/BlockLookup.hpp b/src/world/BlockLookup.hpp index 3d7aa04..214608e 100644 --- a/src/world/BlockLookup.hpp +++ b/src/world/BlockLookup.hpp @@ -2,6 +2,7 @@ #define BLANK_WORLD_BLOCKLOOKUP_HPP_ #include "Block.hpp" +#include "BlockType.hpp" #include "Chunk.hpp" @@ -28,6 +29,8 @@ public: const BlockType &GetType() const noexcept { return GetChunk().Type(GetBlock()); } int GetLight() const noexcept { return GetChunk().GetLight(GetBlockPos()); } + bool FaceFilled(Block::Face f) const noexcept { return GetType().FaceFilled(GetBlock(), f); } + void SetBlock(const Block &b) noexcept { GetChunk().SetBlock(GetBlockPos(), b); } // traverse in given direction