mirror of
https://github.com/neocturne/MinedMap.git
synced 2025-03-04 17:23:33 +01:00
World: Chunk: remove unnecessary level class member
This commit is contained in:
parent
0f6c467566
commit
16a1258f08
2 changed files with 2 additions and 6 deletions
|
@ -18,7 +18,8 @@ namespace MinedMap {
|
|||
namespace World {
|
||||
|
||||
Chunk::Chunk(const ChunkData *data) {
|
||||
level = assertValue(data->getRoot().get<NBT::CompoundTag>("Level"));
|
||||
std::shared_ptr<const NBT::CompoundTag> level =
|
||||
assertValue(data->getRoot().get<NBT::CompoundTag>("Level"));
|
||||
|
||||
std::shared_ptr<const NBT::ListTag> sectionsTag = level->get<NBT::ListTag>("Sections");
|
||||
if (!sectionsTag || sectionsTag->empty())
|
||||
|
|
|
@ -55,7 +55,6 @@ public:
|
|||
};
|
||||
|
||||
private:
|
||||
std::shared_ptr<const NBT::CompoundTag> level;
|
||||
std::vector<std::unique_ptr<Section>> sections;
|
||||
|
||||
std::shared_ptr<const NBT::ByteArrayTag> biomeBytes;
|
||||
|
@ -80,10 +79,6 @@ private:
|
|||
public:
|
||||
Chunk(const ChunkData *data);
|
||||
|
||||
const NBT::CompoundTag & getLevel() const {
|
||||
return *level;
|
||||
}
|
||||
|
||||
uint8_t getBiome(block_idx_t x, y_idx_t y, block_idx_t z) const;
|
||||
Block getBlock(block_idx_t x, Height y, block_idx_t z) const;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue