Advertisement
Guest User

BOP

a guest
May 8th, 2015
268
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.53 KB | None | 0 0
  1. package biomesoplenty.common.biome.overworld;
  2.  
  3. import java.util.Random;
  4.  
  5. import net.minecraft.block.Block;
  6. import net.minecraft.init.Blocks;
  7. import net.minecraft.world.World;
  8. import biomesoplenty.common.biome.BOPOverworldBiome;
  9.  
  10. public class BiomeGenAlps extends BOPOverworldBiome
  11. {
  12. private static final Height biomeHeight = new Height(8.0F, 0.025F);
  13.  
  14. public BiomeGenAlps(int id)
  15. {
  16. super(id);
  17.  
  18. this.setHeight(biomeHeight);
  19. this.setColor(13421772);
  20. this.setEnableSnow();
  21. this.setTemperatureRainfall(0.0F, 0.5F);
  22.  
  23. this.topBlock = Blocks.snow;
  24. this.fillerBlock = Blocks.snow;
  25. this.theBiomeDecorator.treesPerChunk = -999;
  26. this.theBiomeDecorator.flowersPerChunk = -999;
  27. this.theBiomeDecorator.grassPerChunk = -999;
  28. this.theBiomeDecorator.sandPerChunk = -999;
  29. this.theBiomeDecorator.sandPerChunk2 = -999;
  30. }
  31.  
  32. @Override
  33. public void decorate(World world, Random random, int chunkX, int chunkZ)
  34. {
  35. super.decorate(world, random, chunkX, chunkZ);
  36. int var5 = 12 + random.nextInt(6);
  37.  
  38. for (int var6 = 0; var6 < var5; ++var6)
  39. {
  40. int x = chunkX + random.nextInt(16);
  41. int y = random.nextInt(28) + 4;
  42. int z = chunkZ + random.nextInt(16);
  43.  
  44. Block block = world.getBlock(x, y, z);
  45.  
  46. if (block != null && block.isReplaceableOreGen(world, x, y, z, Blocks.stone))
  47. {
  48. world.setBlock(x, y, z, Blocks.emerald_ore, 0, 2);
  49. }
  50. }
  51. }
  52. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement