rjng

Untitled

Jun 5th, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.23 KB | None | 0 0
  1. public void replacechunks()
  2. {
  3. Field biomesField = null;
  4. try
  5. {
  6. biomesField = BiomeBase.class.getDeclaredField("biomes");
  7. }
  8. catch (NoSuchFieldException e)
  9. {
  10. e.printStackTrace();
  11. }
  12. catch (SecurityException e)
  13. {
  14. e.printStackTrace();
  15. }
  16. biomesField.setAccessible(true);
  17. try
  18. {
  19. if ((biomesField.get(null) instanceof BiomeBase[]))
  20. {
  21. BiomeBase[] biomes = (BiomeBase[])biomesField.get(null);
  22. biomes[BiomeBase.BEACH.id] = BiomeBase.PLAINS;
  23. biomes[BiomeBase.BIRCH_FOREST_HILLS.id] = BiomeBase.PLAINS;
  24. biomes[BiomeBase.COLD_BEACH.id] = BiomeBase.PLAINS;
  25. biomes[BiomeBase.COLD_TAIGA.id] = BiomeBase.PLAINS;
  26. biomes[BiomeBase.COLD_TAIGA_HILLS.id] = BiomeBase.PLAINS;
  27. biomes[BiomeBase.DEEP_OCEAN.id] = BiomeBase.PLAINS;
  28. biomes[BiomeBase.FROZEN_OCEAN.id] = BiomeBase.PLAINS;
  29. biomes[BiomeBase.FROZEN_RIVER.id] = BiomeBase.PLAINS;
  30. biomes[BiomeBase.ICE_MOUNTAINS.id] = BiomeBase.PLAINS;
  31. biomes[BiomeBase.ICE_PLAINS.id] = BiomeBase.PLAINS;
  32. biomes[BiomeBase.JUNGLE.id] = BiomeBase.PLAINS;
  33. biomes[BiomeBase.JUNGLE_EDGE.id] = BiomeBase.PLAINS;
  34. biomes[BiomeBase.JUNGLE_HILLS.id] = BiomeBase.PLAINS;
  35. biomes[BiomeBase.MEGA_TAIGA.id] = BiomeBase.PLAINS;
  36. biomes[BiomeBase.MEGA_TAIGA_HILLS.id] = BiomeBase.PLAINS;
  37. biomes[BiomeBase.MESA.id] = BiomeBase.PLAINS;
  38. biomes[BiomeBase.MESA_PLATEAU.id] = BiomeBase.PLAINS;
  39. biomes[BiomeBase.MESA_PLATEAU_F.id] = BiomeBase.PLAINS;
  40. biomes[BiomeBase.MUSHROOM_ISLAND.id] = BiomeBase.PLAINS;
  41. biomes[BiomeBase.MUSHROOM_SHORE.id] = BiomeBase.PLAINS;
  42. biomes[BiomeBase.OCEAN.id] = BiomeBase.PLAINS;
  43. biomes[BiomeBase.ROOFED_FOREST.id] = BiomeBase.PLAINS;
  44. biomes[BiomeBase.SAVANNA_PLATEAU.id] = BiomeBase.PLAINS;
  45. biomes[BiomeBase.TAIGA.id] = BiomeBase.PLAINS;
  46. biomes[BiomeBase.TAIGA_HILLS.id] = BiomeBase.PLAINS;
  47. }
  48. }
  49. catch (IllegalArgumentException e)
  50. {
  51. e.printStackTrace();
  52. }
  53. catch (IllegalAccessException e)
  54. {
  55. e.printStackTrace();
  56. }
  57. }
Advertisement
Add Comment
Please, Sign In to add comment