BiomesOPlenty/src/minecraft/biomesoplenty/biomes/BiomeGenOchreAcres.java

62 lines
1.6 KiB
Java
Raw Normal View History

2013-09-10 00:38:03 +00:00
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenTallGrass;
import net.minecraft.world.gen.feature.WorldGenerator;
import biomesoplenty.api.Blocks;
import biomesoplenty.worldgen.WorldGenDeadTree;
public class BiomeGenOchreAcres extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenOchreAcres(int par1)
{
super(par1);
theBiomeDecorator = new BiomeDecoratorBOP(this);
customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
customBiomeDecorator.treesPerChunk = 4;
customBiomeDecorator.grassPerChunk = 7;
customBiomeDecorator.thornsPerChunk = 1;
2013-09-10 01:15:44 +00:00
customBiomeDecorator.purpleFlowersPerChunk = 6;
2013-09-10 00:38:03 +00:00
customBiomeDecorator.flowersPerChunk = -999;
customBiomeDecorator.reedsPerChunk = -999;
}
/**
* Gets a WorldGen appropriate for this biome.
*/
@Override
public WorldGenerator getRandomWorldGenForGrass(Random par1Random)
{
2013-09-10 01:15:44 +00:00
return par1Random.nextInt(9) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 1) : new WorldGenTallGrass(Blocks.foliage.get().blockID, 2);
2013-09-10 00:38:03 +00:00
}
/**
* Gets a WorldGen appropriate for this biome.
*/
@Override
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
2013-09-10 01:15:44 +00:00
return par1Random.nextInt(3) == 0 ? new WorldGenDeadTree(false) : this.worldGeneratorTrees;
2013-09-10 00:38:03 +00:00
}
/**
* Provides the basic grass color based on the biome temperature and rainfall
*/
@Override
public int getBiomeGrassColor()
{
2013-09-10 01:15:44 +00:00
return 12233056;
2013-09-10 00:38:03 +00:00
}
@Override
public int getBiomeFoliageColor()
{
2013-09-10 01:15:44 +00:00
return 13024603;
2013-09-10 00:38:03 +00:00
}
}