[Bleeding] Add APIs for editing biome data, fix existing code to use persistent biome data. Addresses BUKKIT-1075

By: Mike Primm <mike@primmhome.com>
This commit is contained in:
CraftBukkit/Spigot
2012-03-04 10:41:06 -06:00
parent 5aeda06c72
commit 80ee2d93a8
3 changed files with 34 additions and 6 deletions

View File

@@ -216,7 +216,9 @@ public class CraftChunk implements Chunk {
if (includeBiome) {
biome = new BiomeBase[256];
wcm.getBiomeBlock(biome, x << 4, z << 4, 16, 16);
for (int i = 0; i < 256; i++) {
biome[i] = chunk.a(i & 0xF, i >> 4, wcm);
}
}
if (includeBiomeTempRain) {
@@ -250,7 +252,9 @@ public class CraftChunk implements Chunk {
if (includeBiome) {
biome = new BiomeBase[256];
wcm.getBiomeBlock(biome, x << 4, z << 4, 16, 16);
for (int i = 0; i < 256; i++) {
biome[i] = world.getHandle().getBiome((x << 4) + (i & 0xF), (z << 4) + (i >> 4));
}
}
if (includeBiomeTempRain) {