Guest User

Untitled

a guest
Apr 21st, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.18 KB | None | 0 0
  1. package net.minecraft.src;
  2.  
  3. import java.util.Random;
  4.  
  5. public class WorldGenUFO extends WorldGenerator
  6. {
  7. public WorldGenUFO()
  8. {
  9.  
  10. }
  11.  
  12. public boolean generate(World world, Random rand, int i, int j, int k)
  13. {
  14. if(world.getBlockId(i, j, k)!= Block.sand.blockID || world.getBlockId(i, j, k)!= Block.grass.blockID || world.getBlockId(i, j + 1, k)!= 0)
  15. {
  16. return false;
  17. }
  18. int block = Block.blockSteel.blockID;
  19. for(int z = 0; z < 2; z++) {
  20. k = 2;
  21. for(int q = 0; q < 11; q++ ) {
  22. k++;
  23. i = 2;
  24. for(int a = 0; a < 11; a++) {
  25. world.setBlockWithNotify(i, j + 4, k, block);
  26. i++;
  27. }
  28. }
  29. }
  30.  
  31. for(int z = 0; z < 2; z++) {
  32. k = 1;
  33. for(int q = 0; q < 12; q++ ) {
  34. world.setBlockWithNotify(i, j + 3, k, block);
  35. k++;
  36. }
  37. k = 1;
  38. for(int a = 0; a < 12; a++) {
  39. world.setBlockWithNotify(i, j + 3, k, block);
  40. i++;
  41. }
  42. }
  43. for(int z = 0; z < 2; z++) {
  44. k = 0;
  45. for(int q = 0; q < 12; q++ ) {
  46. world.setBlockWithNotify(i, j + 2, k, block);
  47. k++;
  48. }
  49. k = 0;
  50. for(int a = 0; a < 12; a++) {
  51. world.setBlockWithNotify(i, j + 2, k, block);
  52. i++;
  53. }
  54. }
  55. for(int z = 0; z < 2; z++) {
  56. k = 1;
  57. for(int q = 0; q < 12; q++ ) {
  58. world.setBlockWithNotify(i, j + 1, k, block);
  59. k++;
  60. }
  61. k = 1;
  62. for(int a = 0; a < 12; a++) {
  63. world.setBlockWithNotify(i, j + 1, k, block);
  64. i++;
  65. }
  66. }
  67. for(int z = 0; z < 2; z++) {
  68. k = 2;
  69. for(int q = 0; q < 11; q++ ) {
  70. k++;
  71. i = 2;
  72. for(int a = 0; a < 11; a++) {
  73. world.setBlockWithNotify(i, j, k, block);
  74. i++;
  75. }
  76. }
  77. }
  78. return true;
  79. }
  80. }
Add Comment
Please, Sign In to add comment