Made sure alternator was semi-multithread safe.
This commit is contained in:
parent
533a758799
commit
66673e2f52
@ -21,11 +21,10 @@ public class IslandWorldGeneratorAlternator {
|
||||
this.islandBiomeGenerator = biomeGenerator;
|
||||
}
|
||||
|
||||
public IslandWorldGenerator getIslandChunkGeneratorSystemForWorld(World world, Random random) {
|
||||
public synchronized IslandWorldGenerator getIslandChunkGeneratorSystemForWorld(World world, Random random) {
|
||||
if (!chunkGenerator.containsKey(world.getUID())) {
|
||||
chunkGenerator.put(world.getUID(), new IslandWorldGenerator(world, islandBiomeGenerator.getInstance(), random));
|
||||
}
|
||||
|
||||
return chunkGenerator.get(world.getUID());
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user