Full support for 3D biomes (#714)

* Full support for 3D biomes
Since we're only supporting 1.15+ there's no need to try anything other than compatibility

* this is not part of the PR

* Clipboards should still always be y 0 for biomes
(this "bug" has existed for ages)
This commit is contained in:
dordsor21
2020-10-22 22:18:16 +01:00
committed by GitHub
parent 28f5a7072d
commit c6ef1bc1de
28 changed files with 106 additions and 103 deletions

View File

@ -421,14 +421,14 @@ public class BukkitGetBlocks_1_16_1 extends CharGetBlocks {
if (createCopy) {
copy.storeBiomes(currentBiomes);
}
for (int z = 0, i = 0; z < 16; z++) {
for (int x = 0; x < 16; x++, i++) {
final BiomeType biome = biomes[i];
if (biome != null) {
final Biome craftBiome = BukkitAdapter.adapt(biome);
BiomeBase nmsBiome = CraftBlock.biomeToBiomeBase(craftBiome);
for (int y = 0; y < FaweCache.IMP.WORLD_HEIGHT; y++) {
currentBiomes.setBiome(x >> 2, y >> 2, z >> 2, nmsBiome);
for (int y = 0, i = 0; y < 64; y++) {
for (int z = 0; z < 4; z++) {
for (int x = 0; x < 4; x++, i++) {
final BiomeType biome = biomes[i];
if (biome != null) {
final Biome craftBiome = BukkitAdapter.adapt(biome);
BiomeBase nmsBiome = CraftBlock.biomeToBiomeBase(craftBiome);
currentBiomes.setBiome(x, y, z, nmsBiome);
}
}
}