X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fworld.cpp;h=aea6ec2ec8724b0de2dd5b56d8f58453c7769709;hb=5588a6a9b1e2fb6fee8f1166f855ef497e551a09;hp=6ce0700d2b99e694066ba3ab61e2ef08c5e745d6;hpb=d6435142245c019523b9385048d6d79bdd2565f2;p=blank.git diff --git a/src/world.cpp b/src/world.cpp index 6ce0700..aea6ec2 100644 --- a/src/world.cpp +++ b/src/world.cpp @@ -7,7 +7,7 @@ namespace blank { const BlockType BlockType::DEFAULT; -const CuboidShape BlockType::DEFAULT_SHAPE({{ 0, 0, 0 }, { 1, 1, 1 }}); +const NullShape BlockType::DEFAULT_SHAPE; void BlockType::FillVBO( const glm::vec3 &pos, @@ -138,7 +138,6 @@ void Chunk::Position(const glm::vec3 &pos) { int Chunk::VertexCount() const { - // TODO: query blocks as soon as type shapes are implemented int count = 0; for (const auto &block : blocks) { count += block.type->shape->VertexCount(); @@ -151,9 +150,7 @@ void Chunk::Update() { model.Reserve(VertexCount()); for (size_t i = 0; i < Size(); ++i) { - if (blocks[i].type->visible) { - blocks[i].type->FillModel(ToCoords(i), model); - } + blocks[i].type->FillModel(ToCoords(i), model); } model.Invalidate();