Guest User

Untitled

a guest
Nov 20th, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.05 KB | None | 0 0
  1. package net.minecraft.src;
  2. import java.util.Random;
  3.  
  4. public class mod_Firstblock extends BaseMod
  5. {
  6. public static final Block firstBlock = new BlockFirst(97,0).setHardness(0.5F).setResistance(6.0F).setBlockName("firstblock").setLightValue(1F);
  7.  
  8. public mod_Firstblock()
  9. {
  10. ModLoader.RegisterBlock(firstBlock);
  11. firstBlock.blockIndexInTexture = ModLoader.addOverride("/terrain.png","/firstBlock.png");
  12. ModLoader.AddName(firstBlock, "Hurray for me Ore");
  13.  
  14. ModLoader.AddRecipe(new ItemStack(firstBlock, 2), new Object []{
  15. "**", Character.valueOf('*'), Block.dirt
  16. });
  17. }
  18.  
  19. public void GenerateSurface (World world, Random rand, int chunkX, int chuckZ)
  20. {
  21. for (int i=0; i < 16; i++)
  22. {
  23. int randPosX = chunkX + rand.nextInt(5);
  24. int randPosY = rand.nextint(70);
  25. int randPosZ = chunkZ + rand.nextInt(9);
  26. (new WorldGenMinable(firstBlock.blockID, 25)).generate(world, rand, randPosX, randPosY, randPosZ);
  27. }
  28. }
  29.  
  30. public String Version()
  31. {
  32. return "3.14159265";
  33. }
  34. }
Add Comment
Please, Sign In to add comment