New world format, fixes

This commit is contained in:
MihailRis
2023-11-05 15:32:46 +03:00
committed by GitHub
parent 0c65b13f4e
commit 0cf8382e95
21 changed files with 350 additions and 173 deletions
+7
View File
@@ -29,6 +29,13 @@ shared_ptr<Chunk> ChunksStorage::get(int x, int z) const {
return found->second;
}
void ChunksStorage::remove(int x, int z) {
auto found = chunksMap.find(ivec2(x, z));
if (found != chunksMap.end()) {
chunksMap.erase(found->first);
}
}
// some magic code
void ChunksStorage::getVoxels(VoxelsVolume* volume) const {
voxel* voxels = volume->getVoxels();