Re-added Coral Reef, tweaked Crag biome

This commit is contained in:
Forstride 2016-02-03 17:03:30 -05:00
parent eabba1264d
commit 8f6cda25cd
4 changed files with 72 additions and 0 deletions

View file

@ -79,6 +79,7 @@ public class BOPBiomes
// edge-biomes, sub-biomes and mutated-biomes
public static Optional<BiomeGenBase> mountain_foothills = Optional.absent();
public static Optional<BiomeGenBase> canyon_ravine = Optional.absent();
public static Optional<BiomeGenBase> coral_reef = Optional.absent();
//Biome extensions
public static IExtendedBiome end_extension;

View file

@ -0,0 +1,64 @@
/*******************************************************************************
* 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.BlockTallGrass;
import net.minecraft.init.Blocks;
import net.minecraft.util.BlockPos;
import net.minecraft.world.biome.BiomeGenBase.SpawnListEntry;
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.entities.EntityButterfly;
import biomesoplenty.common.enums.BOPClimates;
import biomesoplenty.common.enums.BOPFlowers;
import biomesoplenty.common.enums.BOPGems;
import biomesoplenty.common.enums.BOPPlants;
import biomesoplenty.common.enums.BOPTrees;
import biomesoplenty.common.enums.BOPWoods;
import biomesoplenty.common.util.biome.GeneratorUtils.ScatterYMethod;
import biomesoplenty.common.world.BOPWorldSettings;
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 biomesoplenty.common.world.feature.tree.GeneratorBigTree;
public class BiomeGenCoralReef extends BOPBiome
{
public BiomeGenCoralReef()
{
// terrain
this.terrainSettings.avgHeight(50).heightVariation(5, 10);
this.setColor(18285);
this.canSpawnInBiome = false;
clearWeights();
// coral
this.addGenerator("pink_coral", GeneratorStage.LILYPAD, (new GeneratorFlora.Builder()).amountPerChunk(15.0F).replace(Blocks.water).with(BOPBlocks.coral.getDefaultState().withProperty(BlockBOPCoral.VARIANT, BlockBOPCoral.CoralType.PINK)).scatterYMethod(ScatterYMethod.AT_GROUND).create());
this.addGenerator("orange_coral", GeneratorStage.LILYPAD, (new GeneratorFlora.Builder()).amountPerChunk(15.0F).replace(Blocks.water).with(BOPBlocks.coral.getDefaultState().withProperty(BlockBOPCoral.VARIANT, BlockBOPCoral.CoralType.ORANGE)).scatterYMethod(ScatterYMethod.AT_GROUND).create());
this.addGenerator("blue_coral", GeneratorStage.LILYPAD, (new GeneratorFlora.Builder()).amountPerChunk(15.0F).replace(Blocks.water).with(BOPBlocks.coral.getDefaultState().withProperty(BlockBOPCoral.VARIANT, BlockBOPCoral.CoralType.BLUE)).scatterYMethod(ScatterYMethod.AT_GROUND).create());
this.addGenerator("glowing_coral", GeneratorStage.LILYPAD, (new GeneratorFlora.Builder()).amountPerChunk(15.0F).replace(Blocks.water).with(BOPBlocks.coral.getDefaultState().withProperty(BlockBOPCoral.VARIANT, BlockBOPCoral.CoralType.GLOWING)).scatterYMethod(ScatterYMethod.AT_GROUND).create());
this.addGenerator("algae", GeneratorStage.LILYPAD, (new GeneratorFlora.Builder()).amountPerChunk(3.0F).replace(Blocks.water).with(BOPBlocks.coral.getDefaultState().withProperty(BlockBOPCoral.VARIANT, BlockBOPCoral.CoralType.ALGAE)).scatterYMethod(ScatterYMethod.AT_GROUND).create());
// gem
this.addGenerator("sapphire", GeneratorStage.SAND, (new GeneratorOreSingle.Builder()).amountPerChunk(12).with(BOPGems.SAPPHIRE).create());
}
@Override
public void applySettings(BOPWorldSettings settings)
{
if (!settings.generateBopGems) {this.removeGenerator("sapphire");}
}
}

View file

@ -40,6 +40,8 @@ public class BiomeGenCrag extends BOPBiome
this.waterColorMultiplier = 944693;
this.skyColor = 4944498;
this.avgDirtDepth = 8;
// gem
this.addGenerator("emeralds", GeneratorStage.SAND, (new GeneratorOreSingle.Builder()).amountPerChunk(12).with(Blocks.emerald_ore.getDefaultState()).create());

View file

@ -21,6 +21,7 @@ import static biomesoplenty.api.biome.BOPBiomes.chaparral;
import static biomesoplenty.api.biome.BOPBiomes.cherry_blossom_grove;
import static biomesoplenty.api.biome.BOPBiomes.cold_desert;
import static biomesoplenty.api.biome.BOPBiomes.coniferous_forest;
import static biomesoplenty.api.biome.BOPBiomes.coral_reef;
import static biomesoplenty.api.biome.BOPBiomes.crag;
import static biomesoplenty.api.biome.BOPBiomes.dead_forest;
import static biomesoplenty.api.biome.BOPBiomes.dead_swamp;
@ -109,6 +110,7 @@ import biomesoplenty.common.biome.overworld.BiomeGenChaparral;
import biomesoplenty.common.biome.overworld.BiomeGenCherryBlossomGrove;
import biomesoplenty.common.biome.overworld.BiomeGenColdDesert;
import biomesoplenty.common.biome.overworld.BiomeGenConiferousForest;
import biomesoplenty.common.biome.overworld.BiomeGenCoralReef;
import biomesoplenty.common.biome.overworld.BiomeGenCrag;
import biomesoplenty.common.biome.overworld.BiomeGenDeadForest;
import biomesoplenty.common.biome.overworld.BiomeGenDeadSwamp;
@ -387,8 +389,10 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
mountain_foothills = registerBOPBiome(new BiomeGenMountain(BiomeGenMountain.MountainType.FOOTHILLS), "Mountain Foothills");
canyon_ravine = registerBOPBiome(new BiomeGenCanyon(BiomeGenCanyon.CanyonType.RAVINE), "Canyon Ravine");
coral_reef = registerBOPBiome(new BiomeGenCoralReef(), "Coral Reef");
setSubBiome(canyon, canyon_ravine);
setSubBiome(BiomeGenBase.ocean, BOPBiomes.coral_reef.get());
}
@ -457,6 +461,7 @@ public class ModBiomes implements BOPBiomes.IBiomeRegistry
// edge-biomes, sub-biomes and mutated-biomes
registerBiomeToDictionary(BOPBiomes.mountain_foothills, Type.HILLS, Type.MOUNTAIN);
registerBiomeToDictionary(BOPBiomes.canyon_ravine, Type.SANDY, Type.HILLS, Type.DRY, Type.HOT);
registerBiomeToDictionary(BOPBiomes.coral_reef, Type.WATER, Type.OCEAN);
}