    001package net.minecraft.world.biome;
    002
    003import net.minecraft.block.Block;
    004import net.minecraft.entity.boss.EntityDragon;
    005import net.minecraft.world.gen.feature.WorldGenSpikes;
    006import net.minecraft.world.gen.feature.WorldGenerator;
    007
    008public class BiomeEndDecorator extends BiomeDecorator
    009{
    010    protected WorldGenerator spikeGen;
    011
    012    public BiomeEndDecorator(BiomeGenBase par1BiomeGenBase)
    013    {
    014        super(par1BiomeGenBase);
    015        this.spikeGen = new WorldGenSpikes(Block.whiteStone.blockID);
    016    }
    017
    018    /**
    019     * The method that does the work of actually decorating chunks
    020     */
    021    protected void decorate()
    022    {
    023        this.generateOres();
    024
    025        if (this.randomGenerator.nextInt(5) == 0)
    026        {
    027            int var1 = this.chunk_X + this.randomGenerator.nextInt(16) + 8;
    028            int var2 = this.chunk_Z + this.randomGenerator.nextInt(16) + 8;
    029            int var3 = this.currentWorld.getTopSolidOrLiquidBlock(var1, var2);
    030
    031            if (var3 > 0)
    032            {
    033                ;
    034            }
    035
    036            this.spikeGen.generate(this.currentWorld, this.randomGenerator, var1, var3, var2);
    037        }
    038
    039        if (this.chunk_X == 0 && this.chunk_Z == 0)
    040        {
    041            EntityDragon var4 = new EntityDragon(this.currentWorld);
    042            var4.setLocationAndAngles(0.0D, 128.0D, 0.0D, this.randomGenerator.nextFloat() * 360.0F, 0.0F);
    043            this.currentWorld.spawnEntityInWorld(var4);
    044        }
    045    }
    046}