Added Overgrown Cliffs and Wisteria Meadow biomes. (Wisteria Meadow is still heavily WIP)

This commit is contained in:
Forstride 2016-02-04 21:02:33 -05:00
parent 165aabd569
commit ca83293303
5 changed files with 200 additions and 2 deletions

View file

@ -57,6 +57,7 @@ public class BOPBiomes
public static Optional<BiomeGenBase> ominous_woods = Optional.absent();
public static Optional<BiomeGenBase> origin_valley = Optional.absent();
public static Optional<BiomeGenBase> outback = Optional.absent();
public static Optional<BiomeGenBase> overgrown_cliffs = Optional.absent();
public static Optional<BiomeGenBase> prairie = Optional.absent();
public static Optional<BiomeGenBase> quagmire = Optional.absent();
public static Optional<BiomeGenBase> rainforest = Optional.absent();
@ -73,6 +74,7 @@ public class BOPBiomes
public static Optional<BiomeGenBase> tundra = Optional.absent();
public static Optional<BiomeGenBase> wasteland = Optional.absent();
public static Optional<BiomeGenBase> wetland = Optional.absent();
public static Optional<BiomeGenBase> wisteria_meadow = Optional.absent();
public static Optional<BiomeGenBase> woodland = Optional.absent();
public static Optional<BiomeGenBase> xeric_shrubland = Optional.absent();

View file

@ -0,0 +1,99 @@
/*******************************************************************************
* Copyright 2015-2016, 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.BlockFlower;
import net.minecraft.block.BlockPlanks;
import net.minecraft.block.BlockTallGrass;
import net.minecraft.block.state.IBlockState;
import net.minecraft.init.Blocks;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.generation.GeneratorStage;
import biomesoplenty.api.biome.generation.GeneratorWeighted;
import biomesoplenty.api.block.BOPBlocks;
import biomesoplenty.common.enums.BOPClimates;
import biomesoplenty.common.enums.BOPFlowers;
import biomesoplenty.common.enums.BOPPlants;
import biomesoplenty.common.world.BOPWorldSettings;
import biomesoplenty.common.world.feature.GeneratorDoubleFlora;
import biomesoplenty.common.world.feature.GeneratorFlora;
import biomesoplenty.common.world.feature.GeneratorGrass;
import biomesoplenty.common.world.feature.GeneratorLakes;
import biomesoplenty.common.world.feature.GeneratorOreSingle;
import biomesoplenty.common.world.feature.tree.GeneratorBasicTree;
import biomesoplenty.common.world.feature.tree.GeneratorBush;
import biomesoplenty.common.world.feature.tree.GeneratorMahoganyTree;
public class BiomeGenOvergrownCliffs extends BOPBiome
{
public BiomeGenOvergrownCliffs()
{
// terrain
this.terrainSettings.avgHeight(70).heightVariation(5, 100).octaves(1, 1, 1, 1, 0, 0).sidewaysNoise(0.0F);
this.setColor(8373350);
this.setTemperatureRainfall(0.8F, 0.7F);
this.canGenerateRivers = false;
this.canSpawnInBiome = false;
this.canGenerateVillages = false;
this.addWeight(BOPClimates.TROPICAL, 2);
this.spawnableCreatureList.clear();
// trees
GeneratorWeighted treeGenerator = new GeneratorWeighted(40.0F);
this.addGenerator("trees", GeneratorStage.TREE, treeGenerator);
treeGenerator.add("mahogany", 1, (new GeneratorMahoganyTree.Builder()).minHeight(5).maxHeight(10).create());
treeGenerator.add("oak_bush", 8, (new GeneratorBush.Builder()).maxHeight(2).create());
// other plants
this.addGenerator("shrubs", GeneratorStage.FLOWERS,(new GeneratorFlora.Builder()).amountPerChunk(0.4F).with(BOPPlants.SHRUB).create());
this.addGenerator("sprouts", GeneratorStage.FLOWERS,(new GeneratorFlora.Builder()).amountPerChunk(0.5F).with(BOPPlants.SPROUT).create());
// flowers
GeneratorWeighted flowerGenerator = new GeneratorWeighted(1.5F);
this.addGenerator("flowers", GeneratorStage.GRASS, flowerGenerator);
flowerGenerator.add("orange_cosmos", 4, (new GeneratorFlora.Builder().with(BOPFlowers.ORANGE_COSMOS).create()));
flowerGenerator.add("dandelion", 1, (new GeneratorFlora.Builder().with(BlockFlower.EnumFlowerType.DANDELION).create()));
flowerGenerator.add("poppy", 1, (new GeneratorFlora.Builder().with(BlockFlower.EnumFlowerType.POPPY).create()));
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(2.0F);
this.addGenerator("grass", GeneratorStage.GRASS, grassGenerator);
grassGenerator.add("shortgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.SHORTGRASS).create());
grassGenerator.add("mediumgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.MEDIUMGRASS).create());
grassGenerator.add("wheatgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.WHEATGRASS).create());
grassGenerator.add("dampgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.DAMPGRASS).create());
grassGenerator.add("tallgrass", 1, (new GeneratorGrass.Builder()).with(BlockTallGrass.EnumType.GRASS).create());
// gem
this.addGenerator("emeralds", GeneratorStage.SAND, (new GeneratorOreSingle.Builder()).amountPerChunk(12).with(Blocks.emerald_ore.getDefaultState()).create());
}
@Override
public void applySettings(BOPWorldSettings settings)
{
if (!settings.generateHotSprings) {this.removeGenerator("hot_springs");}
if (!settings.generateBopFoliage) {this.removeGenerator("caveweed"); this.removeGenerator("bushes"); this.removeGenerator("koru"); this.removeGenerator("shrubs"); this.removeGenerator("leaf_piles"); this.removeGenerator("dead_leaf_piles"); this.removeGenerator("clover_patches"); this.removeGenerator("sprouts");}
if (!settings.generateBopPlants) {this.removeGenerator("cattail"); this.removeGenerator("double_cattail"); this.removeGenerator("river_cane"); this.removeGenerator("tiny_cacti"); this.removeGenerator("roots"); this.removeGenerator("rafflesia"); this.removeGenerator("desert_sprouts");}
GeneratorWeighted flowerGen = (GeneratorWeighted)this.getGenerator("flowers");
if (!settings.generateBopFlowers) {flowerGen.removeGenerator("bluebells"); flowerGen.removeGenerator("clover"); flowerGen.removeGenerator("swampflower"); flowerGen.removeGenerator("deathbloom"); flowerGen.removeGenerator("glowflower"); flowerGen.removeGenerator("blue_hydrangeas"); flowerGen.removeGenerator("pink_daffodil"); flowerGen.removeGenerator("white_anemones"); flowerGen.removeGenerator("orange_cosmos"); flowerGen.removeGenerator("wildflowers"); flowerGen.removeGenerator("violet"); flowerGen.removeGenerator("hibiscus"); flowerGen.removeGenerator("goldenrods"); flowerGen.removeGenerator("icy_irises"); flowerGen.removeGenerator("wilted_lily"); flowerGen.removeGenerator("lily_of_the_valley"); flowerGen.removeGenerator("bromeliad"); this.removeGenerator("bromeliad");}
GeneratorWeighted grassGen = (GeneratorWeighted)this.getGenerator("grass");
if (!settings.generateBopGrasses) {grassGen.removeGenerator("shortgrass"); grassGen.removeGenerator("mediumgrass"); grassGen.removeGenerator("wheatgrass"); grassGen.removeGenerator("dampgrass");}
}
}

View file

@ -22,6 +22,7 @@ import biomesoplenty.common.world.feature.tree.GeneratorBigTree;
import biomesoplenty.common.world.feature.tree.GeneratorBush;
import net.minecraft.block.BlockDoublePlant;
import net.minecraft.block.BlockFlower;
import net.minecraft.block.BlockPlanks;
import net.minecraft.block.BlockTallGrass;
import net.minecraft.block.BlockFlower.EnumFlowerType;
import net.minecraft.block.state.IBlockState;
@ -54,7 +55,8 @@ public class BiomeGenSacredSprings extends BOPBiome
// trees
this.addGenerator("sacred_oak_trees", GeneratorStage.POST, (new GeneratorBigTree.Builder()).amountPerChunk(0.2F).log(BOPWoods.SACRED_OAK).leaves(BOPTrees.SACRED_OAK).minHeight(35).maxHeight(40).trunkWidth(2).foliageDensity(2.0D).create());
this.addGenerator("leaves_clusters", GeneratorStage.TREE, (new GeneratorBush.Builder()).amountPerChunk(12.5F).maxHeight(2).create());
this.addGenerator("large_oak", GeneratorStage.TREE, (new GeneratorBigTree.Builder()).amountPerChunk(3.0F).log(BlockPlanks.EnumType.OAK).leaves(BlockPlanks.EnumType.OAK).create());
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(2.75F);
this.addGenerator("grass", GeneratorStage.GRASS, grassGenerator);

View file

@ -0,0 +1,87 @@
package biomesoplenty.common.biome.overworld;
import net.minecraft.block.BlockDoublePlant;
import net.minecraft.block.BlockFlower;
import net.minecraft.block.BlockPlanks;
import net.minecraft.block.BlockTallGrass;
import net.minecraft.init.Blocks;
import net.minecraft.util.BlockPos;
import biomesoplenty.api.biome.BOPBiome;
import biomesoplenty.api.biome.generation.GeneratorStage;
import biomesoplenty.api.biome.generation.GeneratorWeighted;
import biomesoplenty.api.block.BOPBlocks;
import biomesoplenty.common.block.BlockBOPCoral;
import biomesoplenty.common.block.BlockBOPDoublePlant;
import biomesoplenty.common.block.BlockBOPLilypad;
import biomesoplenty.common.entities.EntityButterfly;
import biomesoplenty.common.entities.EntitySnail;
import biomesoplenty.common.enums.BOPClimates;
import biomesoplenty.common.enums.BOPFlowers;
import biomesoplenty.common.enums.BOPGems;
import biomesoplenty.common.enums.BOPPlants;
import biomesoplenty.common.util.biome.GeneratorUtils.ScatterYMethod;
import biomesoplenty.common.world.BOPWorldSettings;
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 biomesoplenty.common.world.feature.GeneratorWaterside;
import biomesoplenty.common.world.feature.tree.GeneratorBasicTree;
import biomesoplenty.common.world.feature.tree.GeneratorBush;
import biomesoplenty.common.world.feature.tree.GeneratorTaigaTree;
public class BiomeGenWisteriaMeadow extends BOPBiome
{
public BiomeGenWisteriaMeadow()
{
// terrain
this.terrainSettings.avgHeight(64).heightVariation(5, 5).octaves(0, 1, 2, 2, 1, 0).sidewaysNoise(0.1D);
this.setColor(11569864);
this.setTemperatureRainfall(0.8F, 0.4F);
this.addWeight(BOPClimates.COOL_TEMPERATE, 2);
this.spawnableCreatureList.add(new SpawnListEntry(EntityButterfly.class, 6, 2, 4));
//trees
this.addGenerator("trees", GeneratorStage.TREE, (new GeneratorBasicTree.Builder()).amountPerChunk(1.0F).minHeight(6).maxHeight(10).minLeavesRadius(2).create());
// grasses
GeneratorWeighted grassGenerator = new GeneratorWeighted(5.0F);
this.addGenerator("grass", GeneratorStage.GRASS, grassGenerator);
grassGenerator.add("shortgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.SHORTGRASS).create());
grassGenerator.add("mediumgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.MEDIUMGRASS).create());
grassGenerator.add("wheatgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.WHEATGRASS).create());
grassGenerator.add("dampgrass", 1, (new GeneratorGrass.Builder()).with(BOPPlants.DAMPGRASS).create());
grassGenerator.add("tallgrass", 2, (new GeneratorGrass.Builder()).with(BlockTallGrass.EnumType.GRASS).create());
// flowers
GeneratorWeighted flowerGenerator = new GeneratorWeighted(25.0F);
this.addGenerator("flowers", GeneratorStage.GRASS, flowerGenerator);
flowerGenerator.add("clover", 1, (new GeneratorFlora.Builder().with(BOPFlowers.CLOVER).create()));
flowerGenerator.add("white_anemones", 1, (new GeneratorFlora.Builder().with(BOPFlowers.WHITE_ANEMONE).create()));
flowerGenerator.add("houstonia", 2, (new GeneratorFlora.Builder().with(BlockFlower.EnumFlowerType.HOUSTONIA).create()));
flowerGenerator.add("oxeye_daisy", 2, (new GeneratorFlora.Builder().with(BlockFlower.EnumFlowerType.OXEYE_DAISY).create()));
// gem
this.addGenerator("peridot", GeneratorStage.SAND, (new GeneratorOreSingle.Builder()).amountPerChunk(12).with(BOPGems.PERIDOT).create());
}
@Override
public void applySettings(BOPWorldSettings settings)
{
if (!settings.generateBopGems) {this.removeGenerator("peridot");}
if (!settings.generateBopFoliage) {this.removeGenerator("caveweed"); this.removeGenerator("bushes"); this.removeGenerator("koru"); this.removeGenerator("shrubs"); this.removeGenerator("leaf_piles"); this.removeGenerator("dead_leaf_piles"); this.removeGenerator("clover_patches"); this.removeGenerator("sprouts");}
if (!settings.generateBopPlants) {this.removeGenerator("cattail"); this.removeGenerator("double_cattail"); this.removeGenerator("river_cane"); this.removeGenerator("tiny_cacti"); this.removeGenerator("roots"); this.removeGenerator("rafflesia"); this.removeGenerator("desert_sprouts");}
GeneratorWeighted flowerGen = (GeneratorWeighted)this.getGenerator("flowers");
if (!settings.generateBopFlowers) {flowerGen.removeGenerator("bluebells"); flowerGen.removeGenerator("clover"); flowerGen.removeGenerator("swampflower"); flowerGen.removeGenerator("deathbloom"); flowerGen.removeGenerator("glowflower"); flowerGen.removeGenerator("blue_hydrangeas"); flowerGen.removeGenerator("pink_daffodil"); flowerGen.removeGenerator("white_anemones"); flowerGen.removeGenerator("orange_cosmos"); flowerGen.removeGenerator("wildflowers"); flowerGen.removeGenerator("violet"); flowerGen.removeGenerator("hibiscus"); flowerGen.removeGenerator("goldenrods"); flowerGen.removeGenerator("icy_irises"); flowerGen.removeGenerator("wilted_lily"); flowerGen.removeGenerator("lily_of_the_valley"); flowerGen.removeGenerator("bromeliad"); this.removeGenerator("bromeliad");}
GeneratorWeighted grassGen = (GeneratorWeighted)this.getGenerator("grass");
if (!settings.generateBopGrasses) {grassGen.removeGenerator("shortgrass"); grassGen.removeGenerator("mediumgrass"); grassGen.removeGenerator("wheatgrass"); grassGen.removeGenerator("dampgrass");}
}
}

View file

@ -58,6 +58,7 @@ import static biomesoplenty.api.biome.BOPBiomes.mystic_grove;
import static biomesoplenty.api.biome.BOPBiomes.ominous_woods;
import static biomesoplenty.api.biome.BOPBiomes.origin_valley;
import static biomesoplenty.api.biome.BOPBiomes.outback;
import static biomesoplenty.api.biome.BOPBiomes.overgrown_cliffs;
import static biomesoplenty.api.biome.BOPBiomes.plains_extension;
import static biomesoplenty.api.biome.BOPBiomes.prairie;
import static biomesoplenty.api.biome.BOPBiomes.quagmire;
@ -79,6 +80,7 @@ import static biomesoplenty.api.biome.BOPBiomes.tropical_rainforest;
import static biomesoplenty.api.biome.BOPBiomes.tundra;
import static biomesoplenty.api.biome.BOPBiomes.wasteland;
import static biomesoplenty.api.biome.BOPBiomes.wetland;
import static biomesoplenty.api.biome.BOPBiomes.wisteria_meadow;
import static biomesoplenty.api.biome.BOPBiomes.woodland;
import static biomesoplenty.api.biome.BOPBiomes.xeric_shrubland;
@ -138,6 +140,7 @@ import biomesoplenty.common.biome.overworld.BiomeGenMysticGrove;
import biomesoplenty.common.biome.overworld.BiomeGenOminousWoods;
import biomesoplenty.common.biome.overworld.BiomeGenOriginValley;
import biomesoplenty.common.biome.overworld.BiomeGenOutback;
import biomesoplenty.common.biome.overworld.BiomeGenOvergrownCliffs;
import biomesoplenty.common.biome.overworld.BiomeGenPrairie;
import biomesoplenty.common.biome.overworld.BiomeGenQuagmire;
import biomesoplenty.common.biome.overworld.BiomeGenRainforest;
@ -154,6 +157,7 @@ import biomesoplenty.common.biome.overworld.BiomeGenTropicalRainforest;
import biomesoplenty.common.biome.overworld.BiomeGenTundra;
import biomesoplenty.common.biome.overworld.BiomeGenWasteland;
import biomesoplenty.common.biome.overworld.BiomeGenWetland;
import biomesoplenty.common.biome.overworld.BiomeGenWisteriaMeadow;
import biomesoplenty.common.biome.overworld.BiomeGenWoodland;
import biomesoplenty.common.biome.overworld.BiomeGenXericShrubland;
import biomesoplenty.common.biome.vanilla.BiomeExtBirchForest;
@ -366,6 +370,7 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
ominous_woods = registerBOPBiome(new BiomeGenOminousWoods(), "Ominous Woods");
origin_valley = registerBOPBiome(new BiomeGenOriginValley(), "Origin Valley");
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");
@ -380,8 +385,9 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
thicket = registerBOPBiome(new BiomeGenThicket(), "Thicket");
tropical_rainforest = registerBOPBiome(new BiomeGenTropicalRainforest(), "Tropical Rainforest");
tundra = registerBOPBiome(new BiomeGenTundra(), "Tundra");
wetland = registerBOPBiome(new BiomeGenWetland(), "Wetland");
wasteland = registerBOPBiome(new BiomeGenWasteland(), "Wasteland");
wetland = registerBOPBiome(new BiomeGenWetland(), "Wetland");
wisteria_meadow = registerBOPBiome(new BiomeGenWisteriaMeadow(), "Wisteria Meadow");
woodland = registerBOPBiome(new BiomeGenWoodland(), "Woodland");
xeric_shrubland = registerBOPBiome(new BiomeGenXericShrubland(), "Xeric Shrubland");
@ -439,6 +445,7 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
registerBiomeToDictionary(BOPBiomes.ominous_woods, Type.MAGICAL, Type.FOREST, Type.SPOOKY, Type.DEAD);
registerBiomeToDictionary(BOPBiomes.origin_valley, Type.MAGICAL, Type.SPARSE);
registerBiomeToDictionary(BOPBiomes.outback, Type.SANDY, Type.PLAINS, Type.SAVANNA, Type.DRY, Type.HOT);
registerBiomeToDictionary(BOPBiomes.overgrown_cliffs, Type.MOUNTAIN, Type.LUSH, Type.DENSE, Type.JUNGLE);
registerBiomeToDictionary(BOPBiomes.prairie, Type.PLAINS, Type.DRY, Type.SPARSE);
registerBiomeToDictionary(BOPBiomes.quagmire, Type.SWAMP, Type.WATER, Type.DEAD, Type.WET, Type.WASTELAND);
registerBiomeToDictionary(BOPBiomes.rainforest, Type.JUNGLE, Type.FOREST, Type.DENSE, Type.LUSH, Type.HILLS, Type.WET);
@ -455,6 +462,7 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
registerBiomeToDictionary(BOPBiomes.tundra, Type.COLD, Type.WASTELAND, Type.DRY, Type.DEAD, Type.SPARSE);
registerBiomeToDictionary(BOPBiomes.wasteland, Type.WASTELAND, Type.DEAD, Type.SPARSE, Type.DRY);
registerBiomeToDictionary(BOPBiomes.wetland, Type.SWAMP, Type.FOREST, Type.WET, Type.LUSH);
registerBiomeToDictionary(BOPBiomes.wisteria_meadow, Type.PLAINS, Type.FOREST, Type.LUSH, Type.MAGICAL);
registerBiomeToDictionary(BOPBiomes.woodland, Type.FOREST, Type.DRY, Type.DENSE);
registerBiomeToDictionary(BOPBiomes.xeric_shrubland, Type.PLAINS, Type.SPARSE, Type.DRY, Type.LUSH, Type.HOT, Type.SANDY);