Add highland biome

This commit is contained in:
Cheeserolls 2015-05-31 15:50:19 +01:00
parent 502549f8af
commit 7cf4c74420
3 changed files with 63 additions and 0 deletions

View file

@ -20,6 +20,7 @@ public class BOPBiomes
public static Optional<BiomeGenBase> chaparral = Optional.absent(); public static Optional<BiomeGenBase> chaparral = Optional.absent();
public static Optional<BiomeGenBase> denseForest = Optional.absent(); public static Optional<BiomeGenBase> denseForest = Optional.absent();
public static Optional<BiomeGenBase> flowerField = Optional.absent(); public static Optional<BiomeGenBase> flowerField = Optional.absent();
public static Optional<BiomeGenBase> highland = Optional.absent();
public static Optional<BiomeGenBase> lavenderFields = Optional.absent(); public static Optional<BiomeGenBase> lavenderFields = Optional.absent();
public static Optional<BiomeGenBase> originValley = Optional.absent(); public static Optional<BiomeGenBase> originValley = Optional.absent();
public static Optional<BiomeGenBase> shrubland = Optional.absent(); public static Optional<BiomeGenBase> shrubland = Optional.absent();

View file

@ -0,0 +1,61 @@
/*******************************************************************************
* Copyright 2015, the Biomes O' Plenty Team
*
* This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International Public License.
*
* To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
******************************************************************************/
package biomesoplenty.common.biome.overworld;
import net.minecraft.block.BlockDoublePlant;
import net.minecraft.block.BlockTallGrass;
import net.minecraft.init.Blocks;
import net.minecraftforge.common.BiomeManager.BiomeType;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.generation.GeneratorStage;
import biomesoplenty.api.biome.generation.GeneratorWeighted;
import biomesoplenty.common.block.BlockBOPPlant;
import biomesoplenty.common.enums.BOPPlants;
import biomesoplenty.common.world.feature.GeneratorBlobs;
import biomesoplenty.common.world.feature.GeneratorDoubleFlora;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
public class BiomeGenHighland extends BOPBiome
{
private static final Height biomeHeight = new Height(2.5F, 0.5F);
public BiomeGenHighland()
{
this.setHeight(biomeHeight);
this.setColor(0x7CAD66);
this.setTemperatureRainfall(0.5F, 0.8F);
this.addWeight(BiomeType.WARM, 7);
// other plants
this.addGenerator("wild_carrots", GeneratorStage.FLOWERS, new GeneratorFlora(1, BlockBOPPlant.paging.getVariantState(BOPPlants.WILDCARROT)));
// boulders
// TODO: make the generator only run at the surface?
this.addGenerator("boulders", GeneratorStage.SAND, new GeneratorBlobs(4, Blocks.cobblestone.getDefaultState(), 0.3F, 1.2F, 0.5F, 1, Blocks.grass));
this.addGenerator("big_boulders", GeneratorStage.SAND, new GeneratorBlobs(1, Blocks.cobblestone.getDefaultState(), 0.3F, 4.0F, 0.5F, 3, Blocks.grass));
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(100);
this.addGenerator("grass", GeneratorStage.GRASS, grassGenerator);
grassGenerator.add("wheatgrass", 1, new GeneratorGrass(1, BlockBOPPlant.paging.getVariantState(BOPPlants.WHEATGRASS)));
grassGenerator.add("dampgrass", 1, new GeneratorGrass(1, BlockBOPPlant.paging.getVariantState(BOPPlants.DAMPGRASS)));
grassGenerator.add("tallgrass", 1, new GeneratorGrass(1, Blocks.tallgrass.getDefaultState().withProperty(BlockTallGrass.TYPE, BlockTallGrass.EnumType.GRASS)));
grassGenerator.add("doublegrass", 4, new GeneratorDoubleFlora(1, BlockDoublePlant.EnumPlantType.GRASS, 64));
// gem
this.addGenerator("emerald", GeneratorStage.SAND, new GeneratorOreSingle(Blocks.emerald_ore.getDefaultState(), 15, 4, 32));
}
}

View file

@ -78,6 +78,7 @@ public class ModBiomes
chaparral = registerBOPBiome(new BiomeGenChaparral(), "Chaparral"); chaparral = registerBOPBiome(new BiomeGenChaparral(), "Chaparral");
denseForest = registerBOPBiome(new BiomeGenDenseForest(), "Dense Forest"); denseForest = registerBOPBiome(new BiomeGenDenseForest(), "Dense Forest");
flowerField = registerBOPBiome(new BiomeGenFlowerField(), "Flower Field"); flowerField = registerBOPBiome(new BiomeGenFlowerField(), "Flower Field");
highland = registerBOPBiome(new BiomeGenHighland(), "Highland");
lavenderFields = registerBOPBiome(new BiomeGenLavenderFields(), "Lavender Fields"); lavenderFields = registerBOPBiome(new BiomeGenLavenderFields(), "Lavender Fields");
originValley = registerBOPBiome(new BiomeGenOriginValley(), "Origin Valley"); originValley = registerBOPBiome(new BiomeGenOriginValley(), "Origin Valley");
shrubland = registerBOPBiome(new BiomeGenShrubland(), "Shrubland"); shrubland = registerBOPBiome(new BiomeGenShrubland(), "Shrubland");