Updated vanilla biome extensions. 801 errors remaining

This commit is contained in:
Adubbz 2016-03-03 22:26:53 +11:00
parent b76b38a28c
commit f7e8d3a293
33 changed files with 155 additions and 143 deletions

View file

@ -37,6 +37,7 @@ import net.minecraft.entity.EntityLiving;
import net.minecraft.entity.EnumCreatureType;
import net.minecraft.init.Biomes;
import net.minecraft.init.Blocks;
import net.minecraft.util.ResourceLocation;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.chunk.ChunkPrimer;
@ -61,13 +62,13 @@ public class BOPBiome extends BiomeGenBase implements IExtendedBiome
public boolean noNeighborTerrainInfuence = false;
public int avgDirtDepth = 3;
public final String idName;
public final ResourceLocation idLoc;
private BOPBiome(String idName, PropsBuilder defaultBuilder, BOPConfig.IConfigObj conf)
private BOPBiome(ResourceLocation idLoc, PropsBuilder defaultBuilder, BOPConfig.IConfigObj conf)
{
super(configureBiomeProps(idName, defaultBuilder, conf));
super(configureBiomeProps(idLoc, defaultBuilder, conf));
this.idName = idName;
this.idLoc = idLoc;
this.terrainSettings.setDefaults();
this.theBiomeDecorator.treesPerChunk = -999;
@ -81,12 +82,12 @@ public class BOPBiome extends BiomeGenBase implements IExtendedBiome
this.addGenerator("roots", GeneratorStage.FLOWERS,(new GeneratorFlora.Builder()).amountPerChunk(4.0F).with(BOPPlants.ROOT).create());
}
public BOPBiome(String idName, PropsBuilder defaultBuilder)
public BOPBiome(ResourceLocation idLoc, PropsBuilder defaultBuilder)
{
this(idName, defaultBuilder, ModBiomes.readConfigFile(idName));
this(idLoc, defaultBuilder, ModBiomes.readConfigFile(idLoc.getResourcePath()));
}
public static BiomeProps configureBiomeProps(String idName, PropsBuilder defaultBuilder, BOPConfig.IConfigObj conf)
public static BiomeProps configureBiomeProps(ResourceLocation idLoc, PropsBuilder defaultBuilder, BOPConfig.IConfigObj conf)
{
// If there isn't a valid config file, don't use it to configure the biome
if (conf.isEmpty())
@ -128,7 +129,7 @@ public class BOPBiome extends BiomeGenBase implements IExtendedBiome
this.canGenerateVillages = conf.getBool("canGenerateVillages", this.canGenerateVillages);
this.canGenerateRivers = conf.getBool("canGenerateRivers", this.canGenerateRivers);
this.beachBiomeId = conf.getInt("beachBiomeId", this.beachBiomeId);
this.beachBiomeIdLoc = conf.getInt("beachBiomeIdLoc", this.beachBiomeIdLoc);
// Allow weights to be overridden
IConfigObj confWeights = conf.getObject("weights");
@ -389,9 +390,9 @@ public class BOPBiome extends BiomeGenBase implements IExtendedBiome
}
@Override
public String getIdName()
public ResourceLocation getIdLoc()
{
return this.idName;
return this.idLoc;
}
protected static class PropsBuilder

View file

@ -11,6 +11,7 @@ import biomesoplenty.common.enums.BOPPlants;
import biomesoplenty.common.util.config.BOPConfig.IConfigObj;
import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import net.minecraft.util.ResourceLocation;
import net.minecraft.world.biome.BiomeGenBase;
public class ExtendedBiomeWrapper implements IExtendedBiome
@ -19,7 +20,7 @@ public class ExtendedBiomeWrapper implements IExtendedBiome
private GenerationManager generationManager = new GenerationManager();
private Map<BOPClimates, Integer> weightMap = new HashMap<BOPClimates, Integer>();
public int beachBiomeId = BiomeGenBase.beach.biomeID;
public ResourceLocation beachBiomeIdLoc = BiomeGenBase.beach.biomeID;
public ExtendedBiomeWrapper(BiomeGenBase biome)
{
@ -35,7 +36,7 @@ public class ExtendedBiomeWrapper implements IExtendedBiome
@Override
public void configure(IConfigObj conf)
{
this.beachBiomeId = conf.getInt("beachBiomeId", this.beachBiomeId);
this.beachBiomeIdLoc = conf.getInt("beachBiomeIdLoc", this.beachBiomeIdLoc);
// Allow generators to be configured
IConfigObj confGenerators = conf.getObject("generators");
@ -97,7 +98,7 @@ public class ExtendedBiomeWrapper implements IExtendedBiome
@Override
public int getBeachId()
{
return this.beachBiomeId;
return this.beachBiomeIdLoc;
}
@Override

View file

@ -16,6 +16,7 @@ import biomesoplenty.api.biome.generation.IGenerator;
import biomesoplenty.common.enums.BOPClimates;
import biomesoplenty.common.util.config.BOPConfig.IConfigObj;
import biomesoplenty.common.world.BOPWorldSettings;
import net.minecraft.util.ResourceLocation;
import net.minecraft.world.biome.BiomeGenBase;
public interface IExtendedBiome
@ -34,5 +35,5 @@ public interface IExtendedBiome
/**Get the base biome associated with this extension**/
public BiomeGenBase getBaseBiome();
public String getIdName();
public ResourceLocation getIdLoc();
}

View file

@ -23,7 +23,7 @@ public class BiomeGenAlps extends BOPBiome
{
public BiomeGenAlps()
{
super(new BiomeProps("Alps").setGuiColour(13421772).setSnowEnabled().setTemperature(-0.5F).setRainfall(0.3F));
super("alps", new PropsBuilder("Alps").withGuiColour(13421772).withSnowEnabled().withTemperature(-0.5F).withRainfall(0.3F));
// terrain
this.terrainSettings.avgHeight(198).heightVariation(12, 12).octaves(1, 1, 2, 2, 3, 3);

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -14,17 +15,17 @@ import biomesoplenty.common.world.feature.GeneratorDoubleFlora;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtBirchForest extends ExtendedBiomeWrapper
{
public BiomeExtBirchForest()
{
super(BiomeGenBase.birchForest);
super(Biomes.birchForest);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// grasses

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -14,17 +15,17 @@ import biomesoplenty.common.world.feature.GeneratorDoubleFlora;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtBirchForestHills extends ExtendedBiomeWrapper
{
public BiomeExtBirchForestHills()
{
super(BiomeGenBase.birchForestHills);
super(Biomes.birchForestHills);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// grasses

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtColdTaiga extends ExtendedBiomeWrapper
{
public BiomeExtColdTaiga()
{
super(BiomeGenBase.coldTaiga);
super(Biomes.coldTaiga);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(0.5F);

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtColdTaigaHills extends ExtendedBiomeWrapper
{
public BiomeExtColdTaigaHills()
{
super(BiomeGenBase.coldTaigaHills);
super(Biomes.coldTaigaHills);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(0.5F);

View file

@ -11,13 +11,13 @@ import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorLakes;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.block.state.IBlockState;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtDesert extends ExtendedBiomeWrapper
{
public BiomeExtDesert()
{
super(BiomeGenBase.desert);
super(Biomes.desert);
// quicksand
this.addGenerator("quicksand", GeneratorStage.SAND, (new GeneratorLakes.Builder()).amountPerChunk(0.2F).liquid(BOPBlocks.sand.getDefaultState().withProperty(BlockBOPSand.VARIANT, BlockBOPSand.SandType.QUICKSAND)).frozenLiquid((IBlockState)null).create());

View file

@ -7,13 +7,13 @@ import biomesoplenty.common.enums.BOPPlants;
import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtDesertHills extends ExtendedBiomeWrapper
{
public BiomeExtDesertHills()
{
super(BiomeGenBase.desertHills);
super(Biomes.desertHills);
// other plants
this.addGenerator("tiny_cacti", GeneratorStage.FLOWERS,(new GeneratorFlora.Builder()).amountPerChunk(0.3F).with(BOPPlants.TINYCACTUS).create());

View file

@ -9,14 +9,14 @@ import biomesoplenty.common.util.block.BlockQuery.IBlockPosQuery;
import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorCrystals;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.init.Biomes;
import net.minecraft.init.Blocks;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeExtEnd extends ExtendedBiomeWrapper
{
public BiomeExtEnd()
{
super(BiomeGenBase.sky);
super(Biomes.sky);
//celestial crystals
IBlockPosQuery emptyEndstone = BlockQuery.buildAnd().withAltitudeBetween(0, 50).withAirBelow().states(Blocks.end_stone.getDefaultState()).create();

View file

@ -11,13 +11,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.tree.GeneratorBasicTree;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtExtremeHills extends ExtendedBiomeWrapper
{
public BiomeExtExtremeHills()
{
super(BiomeGenBase.extremeHills);
super(Biomes.extremeHills);
// trees
GeneratorWeighted treeGenerator = new GeneratorWeighted(0.3F);

View file

@ -11,13 +11,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.tree.GeneratorBasicTree;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtExtremeHillsPlus extends ExtendedBiomeWrapper
{
public BiomeExtExtremeHillsPlus()
{
super(BiomeGenBase.extremeHillsPlus);
super(Biomes.extremeHillsPlus);
// trees
GeneratorWeighted treeGenerator = new GeneratorWeighted(0.3F);

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -16,17 +17,17 @@ import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import biomesoplenty.common.world.feature.tree.GeneratorBasicTree;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtForest extends ExtendedBiomeWrapper
{
public BiomeExtForest()
{
super(BiomeGenBase.forest);
super(Biomes.forest);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// trees

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -16,17 +17,17 @@ import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import biomesoplenty.common.world.feature.tree.GeneratorBasicTree;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtForestHills extends ExtendedBiomeWrapper
{
public BiomeExtForestHills()
{
super(BiomeGenBase.forestHills);
super(Biomes.forestHills);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// trees

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtIceMountains extends ExtendedBiomeWrapper
{
public BiomeExtIceMountains()
{
super(BiomeGenBase.iceMountains);
super(Biomes.iceMountains);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(0.1F);

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtIcePlains extends ExtendedBiomeWrapper
{
public BiomeExtIcePlains()
{
super(BiomeGenBase.icePlains);
super(Biomes.icePlains);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(0.1F);

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtJungle extends ExtendedBiomeWrapper
{
public BiomeExtJungle()
{
super(BiomeGenBase.jungle);
super(Biomes.jungle);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(5.0F);

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtJungleHills extends ExtendedBiomeWrapper
{
public BiomeExtJungleHills()
{
super(BiomeGenBase.jungleHills);
super(Biomes.jungleHills);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(5.0F);

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -11,17 +12,17 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtMegaTaiga extends ExtendedBiomeWrapper
{
public BiomeExtMegaTaiga()
{
super(BiomeGenBase.megaTaiga);
super(Biomes.megaTaiga);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// grasses

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -11,17 +12,17 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtMegaTaigaHills extends ExtendedBiomeWrapper
{
public BiomeExtMegaTaigaHills()
{
super(BiomeGenBase.megaTaigaHills);
super(Biomes.megaTaigaHills);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// grasses

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtMesa extends ExtendedBiomeWrapper
{
public BiomeExtMesa()
{
super(BiomeGenBase.mesa);
super(Biomes.mesa);
// other plants
this.addGenerator("desertgrass", GeneratorStage.GRASS, (new GeneratorGrass.Builder()).amountPerChunk(0.5F).with(BOPPlants.DESERTGRASS).generationAttempts(8).create());

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtMesaPlateau extends ExtendedBiomeWrapper
{
public BiomeExtMesaPlateau()
{
super(BiomeGenBase.mesaPlateau);
super(Biomes.mesaPlateau);
// other plants
this.addGenerator("desertgrass", GeneratorStage.GRASS, (new GeneratorGrass.Builder()).amountPerChunk(0.5F).with(BOPPlants.DESERTGRASS).generationAttempts(8).create());

View file

@ -7,13 +7,13 @@ import biomesoplenty.common.enums.BOPGems;
import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtMushroomIsland extends ExtendedBiomeWrapper
{
public BiomeExtMushroomIsland()
{
super(BiomeGenBase.mushroomIsland);
super(Biomes.mushroomIsland);
// shrooms
this.addGenerator("flat_mushroom", GeneratorStage.SHROOM,(new GeneratorFlora.Builder()).amountPerChunk(0.4F).with(BlockBOPMushroom.MushroomType.FLAT_MUSHROOM).create());

View file

@ -5,13 +5,13 @@ import biomesoplenty.api.biome.generation.GeneratorStage;
import biomesoplenty.common.enums.BOPGems;
import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtOcean extends ExtendedBiomeWrapper
{
public BiomeExtOcean()
{
super(BiomeGenBase.ocean);
super(Biomes.ocean);
// gem
this.addGenerator("sapphire", GeneratorStage.SAND, (new GeneratorOreSingle.Builder()).amountPerChunk(12).with(BOPGems.SAPPHIRE).create());

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtPlains extends ExtendedBiomeWrapper
{
public BiomeExtPlains()
{
super(BiomeGenBase.plains);
super(Biomes.plains);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(5.0F);

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtRoofedForest extends ExtendedBiomeWrapper
{
public BiomeExtRoofedForest()
{
super(BiomeGenBase.roofedForest);
super(Biomes.roofedForest);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(2.0F);

View file

@ -14,13 +14,13 @@ import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorLakes;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.block.state.IBlockState;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtSavanna extends ExtendedBiomeWrapper
{
public BiomeExtSavanna()
{
super(BiomeGenBase.savanna);
super(Biomes.savanna);
// quicksand
this.addGenerator("quicksand", GeneratorStage.SAND, (new GeneratorLakes.Builder()).amountPerChunk(0.1F).liquid(BOPBlocks.sand.getDefaultState().withProperty(BlockBOPSand.VARIANT, BlockBOPSand.SandType.QUICKSAND)).frozenLiquid((IBlockState)null).create());

View file

@ -10,13 +10,13 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtSavannaPlateau extends ExtendedBiomeWrapper
{
public BiomeExtSavannaPlateau()
{
super(BiomeGenBase.savannaPlateau);
super(Biomes.savannaPlateau);
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(4.0F);

View file

@ -23,14 +23,14 @@ import biomesoplenty.common.world.feature.GeneratorOreSingle;
import biomesoplenty.common.world.feature.GeneratorWaterside;
import biomesoplenty.common.world.feature.tree.GeneratorBasicTree;
import net.minecraft.block.BlockOldLeaf;
import net.minecraft.init.Biomes;
import net.minecraft.init.Blocks;
import net.minecraft.world.biome.BiomeGenBase;
public class BiomeExtSwampland extends ExtendedBiomeWrapper
{
public BiomeExtSwampland()
{
super(BiomeGenBase.swampland);
super(Biomes.swampland);
// trees
GeneratorWeighted treeGenerator = new GeneratorWeighted(0.5F);

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -11,17 +12,17 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtTaiga extends ExtendedBiomeWrapper
{
public BiomeExtTaiga()
{
super(BiomeGenBase.taiga);
super(Biomes.taiga);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// grasses

View file

@ -1,5 +1,6 @@
package biomesoplenty.common.biome.vanilla;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.BOPBiomes;
import biomesoplenty.api.biome.ExtendedBiomeWrapper;
import biomesoplenty.api.biome.generation.GeneratorStage;
@ -11,17 +12,17 @@ import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.init.Biomes;
public class BiomeExtTaigaHills extends ExtendedBiomeWrapper
{
public BiomeExtTaigaHills()
{
super(BiomeGenBase.taigaHills);
super(Biomes.taigaHills);
if (BOPBiomes.gravel_beach.isPresent())
{
this.beachBiomeId = BOPBiomes.gravel_beach.get().biomeID;
this.beachBiomeIdLoc = ((BOPBiome)BOPBiomes.gravel_beach.get()).getIdLoc();
}
// grasses

View file

@ -322,69 +322,69 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
{
// beach biomes (normal biomes rely on these being registered first)
gravel_beach = registerBOPBiome(new BiomeGenGravelBeach(), "Gravel Beach");
gravel_beach = registerBOPBiome(new BiomeGenGravelBeach());
// normal biomes which have weights
alps = registerBOPBiome(new BiomeGenAlps(), "Alps");
bamboo_forest = registerBOPBiome(new BiomeGenBambooForest(), "Bamboo Forest");
bayou = registerBOPBiome(new BiomeGenBayou(), "Bayou");
bog = registerBOPBiome(new BiomeGenBog(), "Bog");
boreal_forest = registerBOPBiome(new BiomeGenBorealForest(), "Boreal Forest");
brushland = registerBOPBiome(new BiomeGenBrushland(), "Brushland");
chaparral = registerBOPBiome(new BiomeGenChaparral(), "Chaparral");
cherry_blossom_grove = registerBOPBiome(new BiomeGenCherryBlossomGrove(), "Cherry Blossom Grove");
cold_desert = registerBOPBiome(new BiomeGenColdDesert(), "Cold Desert");
coniferous_forest = registerBOPBiome(new BiomeGenConiferousForest(), "Coniferous Forest");
crag = registerBOPBiome(new BiomeGenCrag(), "Crag");
dead_forest = registerBOPBiome(new BiomeGenDeadForest(), "Dead Forest");
dead_swamp = registerBOPBiome(new BiomeGenDeadSwamp(), "Dead Swamp");
eucalyptus_forest = registerBOPBiome(new BiomeGenEucalyptusForest(), "Eucalyptus Forest");
fen = registerBOPBiome(new BiomeGenFen(), "Fen");
flower_field = registerBOPBiome(new BiomeGenFlowerField(), "Flower Field");
grassland = registerBOPBiome(new BiomeGenGrassland(), "Grassland");
grove = registerBOPBiome(new BiomeGenGrove(), "Grove");
heathland = registerBOPBiome(new BiomeGenHeathland(), "Heathland");
highland = registerBOPBiome(new BiomeGenHighland(), "Highland");
land_of_lakes = registerBOPBiome(new BiomeGenLandOfLakes(), "Land Of Lakes");
lavender_fields = registerBOPBiome(new BiomeGenLavenderFields(), "Lavender Fields");
lush_desert = registerBOPBiome(new BiomeGenLushDesert(), "Lush Desert");
lush_swamp = registerBOPBiome(new BiomeGenLushSwamp(), "Lush Swamp");
maple_woods = registerBOPBiome(new BiomeGenMapleWoods(), "Maple Woods");
marsh = registerBOPBiome(new BiomeGenMarsh(), "Marsh");
meadow = registerBOPBiome(new BiomeGenMeadow(), "Meadow");
moor = registerBOPBiome(new BiomeGenMoor(), "Moor");
mountain = registerBOPBiome(new BiomeGenMountain(BiomeGenMountain.MountainType.PEAKS), "Mountain");
mystic_grove = registerBOPBiome(new BiomeGenMysticGrove(), "Mystic Grove");
ominous_woods = registerBOPBiome(new BiomeGenOminousWoods(), "Ominous Woods");
orchard = registerBOPBiome(new BiomeGenOrchard(), "Orchard");
outback = registerBOPBiome(new BiomeGenOutback(), "Outback");
overgrown_cliffs = registerBOPBiome(new BiomeGenOvergrownCliffs(), "Overgrown Cliffs");
prairie = registerBOPBiome(new BiomeGenPrairie(), "Prairie");
quagmire = registerBOPBiome(new BiomeGenQuagmire(), "Quagmire");
rainforest = registerBOPBiome(new BiomeGenRainforest(), "Rainforest");
redwood_forest = registerBOPBiome(new BiomeGenRedwoodForest(), "Redwood Forest");
sacred_springs = registerBOPBiome(new BiomeGenSacredSprings(), "Sacred Springs");
seasonal_forest = registerBOPBiome(new BiomeGenSeasonalForest(), "Seasonal Forest");
shield = registerBOPBiome(new BiomeGenShield(), "Shield");
shrubland = registerBOPBiome(new BiomeGenShrubland(), "Shrubland");
snowy_coniferous_forest = registerBOPBiome(new BiomeGenSnowyConiferousForest(), "Snowy Coniferous Forest");
snowy_forest = registerBOPBiome(new BiomeGenSnowyForest(), "Snowy Forest");
steppe = registerBOPBiome(new BiomeGenSteppe(), "Steppe");
temperate_rainforest = registerBOPBiome(new BiomeGenTemperateRainforest(), "Temperate Rainforest");
tropical_rainforest = registerBOPBiome(new BiomeGenTropicalRainforest(), "Tropical Rainforest");
tundra = registerBOPBiome(new BiomeGenTundra(), "Tundra");
wasteland = registerBOPBiome(new BiomeGenWasteland(), "Wasteland");
wetland = registerBOPBiome(new BiomeGenWetland(), "Wetland");
woodland = registerBOPBiome(new BiomeGenWoodland(), "Woodland");
xeric_shrubland = registerBOPBiome(new BiomeGenXericShrubland(), "Xeric Shrubland");
alps = registerBOPBiome(new BiomeGenAlps());
bamboo_forest = registerBOPBiome(new BiomeGenBambooForest());
bayou = registerBOPBiome(new BiomeGenBayou());
bog = registerBOPBiome(new BiomeGenBog());
boreal_forest = registerBOPBiome(new BiomeGenBorealForest());
brushland = registerBOPBiome(new BiomeGenBrushland());
chaparral = registerBOPBiome(new BiomeGenChaparral());
cherry_blossom_grove = registerBOPBiome(new BiomeGenCherryBlossomGrove());
cold_desert = registerBOPBiome(new BiomeGenColdDesert());
coniferous_forest = registerBOPBiome(new BiomeGenConiferousForest());
crag = registerBOPBiome(new BiomeGenCrag());
dead_forest = registerBOPBiome(new BiomeGenDeadForest());
dead_swamp = registerBOPBiome(new BiomeGenDeadSwamp());
eucalyptus_forest = registerBOPBiome(new BiomeGenEucalyptusForest());
fen = registerBOPBiome(new BiomeGenFen());
flower_field = registerBOPBiome(new BiomeGenFlowerField());
grassland = registerBOPBiome(new BiomeGenGrassland());
grove = registerBOPBiome(new BiomeGenGrove());
heathland = registerBOPBiome(new BiomeGenHeathland());
highland = registerBOPBiome(new BiomeGenHighland());
land_of_lakes = registerBOPBiome(new BiomeGenLandOfLakes());
lavender_fields = registerBOPBiome(new BiomeGenLavenderFields());
lush_desert = registerBOPBiome(new BiomeGenLushDesert());
lush_swamp = registerBOPBiome(new BiomeGenLushSwamp());
maple_woods = registerBOPBiome(new BiomeGenMapleWoods());
marsh = registerBOPBiome(new BiomeGenMarsh());
meadow = registerBOPBiome(new BiomeGenMeadow());
moor = registerBOPBiome(new BiomeGenMoor());
mountain = registerBOPBiome(new BiomeGenMountain(BiomeGenMountain.MountainType.PEAKS));
mystic_grove = registerBOPBiome(new BiomeGenMysticGrove());
ominous_woods = registerBOPBiome(new BiomeGenOminousWoods());
orchard = registerBOPBiome(new BiomeGenOrchard());
outback = registerBOPBiome(new BiomeGenOutback());
overgrown_cliffs = registerBOPBiome(new BiomeGenOvergrownCliffs());
prairie = registerBOPBiome(new BiomeGenPrairie());
quagmire = registerBOPBiome(new BiomeGenQuagmire());
rainforest = registerBOPBiome(new BiomeGenRainforest());
redwood_forest = registerBOPBiome(new BiomeGenRedwoodForest());
sacred_springs = registerBOPBiome(new BiomeGenSacredSprings());
seasonal_forest = registerBOPBiome(new BiomeGenSeasonalForest());
shield = registerBOPBiome(new BiomeGenShield());
shrubland = registerBOPBiome(new BiomeGenShrubland());
snowy_coniferous_forest = registerBOPBiome(new BiomeGenSnowyConiferousForest());
snowy_forest = registerBOPBiome(new BiomeGenSnowyForest());
steppe = registerBOPBiome(new BiomeGenSteppe());
temperate_rainforest = registerBOPBiome(new BiomeGenTemperateRainforest());
tropical_rainforest = registerBOPBiome(new BiomeGenTropicalRainforest());
tundra = registerBOPBiome(new BiomeGenTundra());
wasteland = registerBOPBiome(new BiomeGenWasteland());
wetland = registerBOPBiome(new BiomeGenWetland());
woodland = registerBOPBiome(new BiomeGenWoodland());
xeric_shrubland = registerBOPBiome(new BiomeGenXericShrubland());
// edge-biomes, sub-biomes and mutated-biomes
mountain_foothills = registerBOPBiome(new BiomeGenMountain(BiomeGenMountain.MountainType.FOOTHILLS), "Mountain Foothills");
glacier = registerBOPBiome(new BiomeGenGlacier(), "Glacier");
oasis = registerBOPBiome(new BiomeGenOasis(), "Oasis");
coral_reef = registerBOPBiome(new BiomeGenCoralReef(), "Coral Reef");
kelp_forest = registerBOPBiome(new BiomeGenKelpForest(), "Kelp Forest");
mountain_foothills = registerBOPBiome(new BiomeGenMountain(BiomeGenMountain.MountainType.FOOTHILLS));
glacier = registerBOPBiome(new BiomeGenGlacier());
oasis = registerBOPBiome(new BiomeGenOasis());
coral_reef = registerBOPBiome(new BiomeGenCoralReef());
kelp_forest = registerBOPBiome(new BiomeGenKelpForest());
setSubBiome(Optional.of(Biomes.icePlains), BOPBiomes.glacier);
setSubBiome(Optional.of(Biomes.desert), BOPBiomes.oasis);
@ -393,10 +393,10 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
// island biomes
origin_island = registerBOPBiome(new BiomeGenOriginIsland(), "Origin Island");
tropical_island = registerBOPBiome(new BiomeGenTropicalIsland(), "Tropical Island");
volcanic_island = registerBOPBiome(new BiomeGenVolcanicIsland(), "Volcanic Island");
flower_island = registerBOPBiome(new BiomeGenFlowerIsland(), "Flower Island");
origin_island = registerBOPBiome(new BiomeGenOriginIsland());
tropical_island = registerBOPBiome(new BiomeGenTropicalIsland());
volcanic_island = registerBOPBiome(new BiomeGenVolcanicIsland());
flower_island = registerBOPBiome(new BiomeGenFlowerIsland());
addIslandBiome(origin_island, 1);
addIslandBiome(tropical_island, 3);
@ -516,7 +516,7 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
//Add to the set of present biomes
presentBiomes.add(extendedBiome.getBaseBiome());
configureBiome(extendedBiome, idName);
extendedBiome.configureBiome(extendedBiome, idName);
//Extra functionality builtin, such as with BOPBiome
if (extendedBiome instanceof BiomeGenBase)
@ -625,8 +625,9 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
return BOPBiomes.REG_INSTANCE.registerBiome(extendedBiome, idName);
}
private static Optional<BiomeGenBase> registerBOPBiome(BOPBiome biome, String idName)
private static Optional<BiomeGenBase> registerBOPBiome(BOPBiome biome)
{
String idName = biome.getIdName();
Integer id = biomeIdMapConf.getInt(idName, null);
if (id == null) {id = new Integer(getNextFreeBiomeId());}
biomeIdMap.put(idName, id);