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

57 lines
1.4 KiB
Java
Raw Normal View History

2013-05-03 13:00:44 +00:00
package biomesoplenty.biomes;
import java.awt.Color;
import net.minecraft.block.Block;
import net.minecraft.world.biome.BiomeGenBase;
import biomesoplenty.configuration.BOPConfiguration;
2013-05-03 13:00:44 +00:00
public class BiomeGenDunes extends BiomeGenBase
{
private BiomeDecoratorBOP customBiomeDecorator;
public BiomeGenDunes(int par1)
{
super(par1);
this.spawnableCreatureList.clear();
this.topBlock = (byte)Block.sand.blockID;
this.fillerBlock = (byte)Block.sand.blockID;
this.theBiomeDecorator = new BiomeDecoratorBOP(this);
this.customBiomeDecorator = (BiomeDecoratorBOP)theBiomeDecorator;
this.customBiomeDecorator.treesPerChunk = -999;
this.customBiomeDecorator.deadBushPerChunk = -999;
this.customBiomeDecorator.duneGrassPerChunk = 10;
this.customBiomeDecorator.desertSproutsPerChunk = 5;
this.customBiomeDecorator.aloePerChunk = 1;
2013-05-03 13:00:44 +00:00
this.customBiomeDecorator.reedsPerChunk = -999;
this.customBiomeDecorator.generateLakes = false;
}
/**
* takes temperature, returns color
*/
public int getSkyColorByTemp(float par1)
{
if (BOPConfiguration.skyColors = true)
{
return 14203007;
}
else
{
par1 /= 3.0F;
if (par1 < -1.0F)
{
par1 = -1.0F;
}
if (par1 > 1.0F)
{
par1 = 1.0F;
}
return Color.getHSBColor(0.62222224F - par1 * 0.05F, 0.5F + par1 * 0.1F, 1.0F).getRGB();
}
}
}