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

55 lines
1.6 KiB
Java
Raw Normal View History

2013-05-03 13:00:44 +00:00
package biomesoplenty.biomes;
import java.util.Random;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.feature.WorldGenerator;
2013-05-03 13:00:44 +00:00
import biomesoplenty.api.Blocks;
import biomesoplenty.worldgen.WorldGenCanyonShrub;
import biomesoplenty.worldgen.WorldGenPineTree;
2013-05-03 13:00:44 +00:00
public class BiomeGenCanyon extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenCanyon(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.topBlock = (byte)Blocks.hardDirt.get().blockID;
this.fillerBlock = (byte)Blocks.hardDirt.get().blockID;
this.customBiomeDecorator.treesPerChunk = 7;
2013-05-03 13:00:44 +00:00
this.customBiomeDecorator.flowersPerChunk = -999;
2013-05-05 00:06:17 +00:00
this.customBiomeDecorator.canyonGrassPerChunk = 5;
this.customBiomeDecorator.aloePerChunk = 2;
2013-05-03 13:00:44 +00:00
this.customBiomeDecorator.generatePumpkins = false;
2013-05-05 00:06:17 +00:00
this.customBiomeDecorator.generateCanyon = true;
2013-05-03 13:00:44 +00:00
}
/**
* Gets a WorldGen appropriate for this biome.
*/
public WorldGenerator getRandomWorldGenForTrees(Random par1Random)
{
return (WorldGenerator)(par1Random.nextInt(9) == 0 ? new WorldGenPineTree() : new WorldGenCanyonShrub(0,0));
2013-05-03 13:00:44 +00:00
}
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeFoliageColor()
{
return 11123300;
}
2013-05-05 00:06:17 +00:00
/**
* Provides the basic foliage color based on the biome temperature and rainfall
*/
public int getBiomeGrassColor()
{
return 11123300;
}
2013-05-03 13:00:44 +00:00
}