Biomes with id -1 are no longer added to the generation lists

This commit is contained in:
Adubbz 2015-04-07 11:42:59 +10:00
parent 587a34337d
commit a3bb33d3aa

View file

@ -119,19 +119,22 @@ public class JsonBiome
extendedBiome.clearWeights(); extendedBiome.clearWeights();
//TODO: Add a system for making Vanilla biome weights configurable. This won't necessarily be in this class, however it's worth noting. //TODO: Add a system for making Vanilla biome weights configurable. This won't necessarily be in this class, however it's worth noting.
for (Entry<BiomeType, Integer> entry : weightMap.entrySet()) if (biome.biomeID != -1)
{ {
if (entry != null) for (Entry<BiomeType, Integer> entry : weightMap.entrySet())
{ {
BiomeType biomeType = entry.getKey(); if (entry != null)
int weight = entry.getValue(); {
BiomeType biomeType = entry.getKey();
//Updates the biome's weights to be in line with the config file int weight = entry.getValue();
extendedBiome.addWeight(biomeType, weight);
BOPBiomeManager.addBiome(biomeType, new BiomeEntry(biome, weight)); //Updates the biome's weights to be in line with the config file
extendedBiome.addWeight(biomeType, weight);
BOPBiomeManager.addBiome(biomeType, new BiomeEntry(biome, weight));
}
} }
} }
biome.biomeName = jsonBiome.biomeName; biome.biomeName = jsonBiome.biomeName;
biome.topBlock = jsonBiome.topBlock; biome.topBlock = jsonBiome.topBlock;
biome.fillerBlock = jsonBiome.fillerBlock; biome.fillerBlock = jsonBiome.fillerBlock;