Last active
July 26, 2020 15:09
-
-
Save BalintCsala/f62a9bbd43a8d01aee56768a48b8cc52 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void StructureFeature::addFeature(Dimension &dimension, Random &random, ChunkPos &chunkPos, BiomeSource &biomeSource) { | |
code *pcVar1; | |
bool uVar5; | |
undefined8 extraout_RDX; | |
unique_ptr<StructureStart> structureStart; | |
nextInt(); | |
std::shared_lock lock1; | |
// lock1 dies | |
if (this->structure_start_locations.count() == 0) { | |
Level level = dimension.getLevel(); | |
uint seed = level.getSeed(); | |
if (this->isFeatureChunk(biomeSource, random, chunkPos, (ulong)seed)) { | |
std::unique_lock lock2; | |
if (this->structure_start_locations.count() == 0) { | |
structureStart->createStructureStart(this, dimension, biomeSource, random, chunkPos); | |
level = this->structure_start_locations[chunkPos]; | |
level = structureStart; // Possibly level.structureStart = structureStart or smthg | |
// structureStart dies | |
} | |
// lock2 dies | |
} | |
} | |
return; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment