Lisenochek

Untitled

Sep 5th, 2016
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.69 KB | None | 0 0
  1. package com.realistic.temperture;
  2.  
  3. import java.util.Random;
  4.  
  5. import org.bukkit.Bukkit;
  6. import org.bukkit.block.Biome;
  7. import org.bukkit.entity.Player;
  8.  
  9. import com.realistic.list.MinecraftList;
  10.  
  11. public class Temperture {
  12.  
  13. private static final Random r = new Random();
  14. private static MinecraftList ml;
  15.  
  16. public Temperture(MinecraftList ml) {
  17. this.ml = ml;
  18. }
  19.  
  20. public static String getBiome(Biome biome) {
  21.  
  22. for (Player p : Bukkit.getOnlinePlayers()) {
  23.  
  24. Biome b = p.getLocation().getBlock().getBiome();
  25.  
  26. if (b == Biome.BEACH) {
  27.  
  28. String s = "+19";
  29. return s;
  30. }
  31.  
  32. if (b == Biome.BIRCH_FOREST) {
  33.  
  34. String s = "+14";
  35. return s;
  36. }
  37.  
  38. if (b == Biome.BIRCH_FOREST_HILLS) {
  39.  
  40. String s = "+11";
  41. return s;
  42. }
  43.  
  44. if (b == Biome.BIRCH_FOREST_HILLS_MOUNTAINS) {
  45.  
  46. String s = "+12";
  47. return s;
  48. }
  49.  
  50. if (b == Biome.BIRCH_FOREST_MOUNTAINS) {
  51.  
  52. String s = "+13";
  53. return s;
  54. }
  55.  
  56. if (b == Biome.COLD_BEACH) {
  57.  
  58. String s = "+5";
  59. return s;
  60. }
  61.  
  62. if (b == Biome.COLD_TAIGA) {
  63.  
  64. String s = "-10";
  65. return s;
  66. }
  67.  
  68. if (b == Biome.COLD_TAIGA_HILLS) {
  69.  
  70. String s = "-11";
  71. return s;
  72. }
  73.  
  74. if (b == Biome.COLD_TAIGA_MOUNTAINS) {
  75.  
  76. String s = "-9";
  77. return s;
  78. }
  79.  
  80. if (b == Biome.DEEP_OCEAN) {
  81.  
  82. String s = "-5";
  83. return s;
  84. }
  85.  
  86. if (b == Biome.DESERT) {
  87.  
  88. String s = "+35";
  89. return s;
  90. }
  91.  
  92. if (b == Biome.DESERT_HILLS) {
  93.  
  94. String s = "+36";
  95. return s;
  96. }
  97.  
  98. if (b == Biome.DESERT_MOUNTAINS) {
  99.  
  100. String s = "+40";
  101. return s;
  102. }
  103.  
  104. if (b == Biome.EXTREME_HILLS) {
  105.  
  106. String s = "-19";
  107. return s;
  108. }
  109.  
  110. if (b == Biome.EXTREME_HILLS_MOUNTAINS) {
  111.  
  112. String s = "-20";
  113. return s;
  114. }
  115.  
  116. if (b == Biome.EXTREME_HILLS_PLUS) {
  117.  
  118. String s = "-21";
  119. return s;
  120. }
  121.  
  122. if (b == Biome.EXTREME_HILLS_PLUS_MOUNTAINS) {
  123.  
  124. String s = "-18";
  125. return s;
  126. }
  127.  
  128. if (b == Biome.FLOWER_FOREST) {
  129.  
  130. String s = "+14";
  131. return s;
  132. }
  133.  
  134. if (b == Biome.FOREST) {
  135.  
  136. String s = "+16";
  137.  
  138. ml.Temp.put(p.getName(), true);
  139.  
  140. return s;
  141. } else {
  142.  
  143. ml.Temp.remove(p.getName());
  144. }
  145.  
  146. if (b == Biome.FOREST_HILLS) {
  147.  
  148. String s = "+15";
  149. return s;
  150. }
  151.  
  152. if (b == Biome.FROZEN_OCEAN) {
  153.  
  154. String s = "-17";
  155. return s;
  156. }
  157.  
  158. if (b == Biome.FROZEN_RIVER) {
  159.  
  160. String s = "-16";
  161. return s;
  162. }
  163.  
  164. if (b == Biome.HELL) {
  165.  
  166. String s = "+50";
  167. return s;
  168. }
  169.  
  170. if (b == Biome.ICE_MOUNTAINS) {
  171.  
  172. String s = "-28";
  173. return s;
  174. }
  175.  
  176. if (b == Biome.ICE_PLAINS) {
  177.  
  178. String s = "-30";
  179. return s;
  180. }
  181.  
  182. if (b == Biome.ICE_PLAINS_SPIKES) {
  183.  
  184. String s = "-31";
  185. return s;
  186. }
  187.  
  188. if (b == Biome.JUNGLE) {
  189.  
  190. String s = "+28";
  191. return s;
  192. }
  193.  
  194. if (b == Biome.JUNGLE_EDGE) {
  195.  
  196. String s = "+27";
  197. return s;
  198. }
  199.  
  200. if (b == Biome.JUNGLE_EDGE_MOUNTAINS) {
  201.  
  202. String s = "+24";
  203. return s;
  204. }
  205.  
  206. if (b == Biome.JUNGLE_HILLS) {
  207.  
  208. String s = "+26";
  209. return s;
  210. }
  211.  
  212. if (b == Biome.JUNGLE_MOUNTAINS) {
  213.  
  214. String s = "+23";
  215. return s;
  216. }
  217.  
  218. if (b == Biome.MEGA_SPRUCE_TAIGA) {
  219.  
  220. String s = "-17";
  221. return s;
  222. }
  223.  
  224. if (b == Biome.MEGA_SPRUCE_TAIGA_HILLS) {
  225.  
  226. String s = "-16";
  227. return s;
  228. }
  229.  
  230. if (b == Biome.MEGA_TAIGA) {
  231.  
  232. String s = "-18";
  233. return s;
  234. }
  235.  
  236. if (b == Biome.MEGA_TAIGA_HILLS) {
  237.  
  238. String s = "-19";
  239. return s;
  240. }
  241.  
  242. if (b == Biome.MESA) {
  243.  
  244. String s = "+19";
  245. return s;
  246. }
  247.  
  248. if (b == Biome.MESA_BRYCE) {
  249.  
  250. String s = "+20";
  251. return s;
  252. }
  253.  
  254. if (b == Biome.MESA_PLATEAU) {
  255.  
  256. String s = "+21";
  257. return s;
  258. }
  259.  
  260. if (b == Biome.MESA_PLATEAU_FOREST) {
  261.  
  262. String s = "+18";
  263. return s;
  264. }
  265.  
  266. if (b == Biome.MESA_PLATEAU_FOREST_MOUNTAINS) {
  267.  
  268. String s = "+16";
  269. return s;
  270. }
  271.  
  272. if (b == Biome.MESA_PLATEAU_MOUNTAINS) {
  273.  
  274. String s = "+20";
  275. return s;
  276. }
  277.  
  278. if (b == Biome.MUSHROOM_ISLAND) {
  279.  
  280. String s = "+12";
  281. return s;
  282. }
  283.  
  284. if (b == Biome.MUSHROOM_SHORE) {
  285.  
  286. String s = "+13";
  287. return s;
  288. }
  289.  
  290. if (b == Biome.OCEAN) {
  291.  
  292. String s = "+22";
  293. return s;
  294. }
  295.  
  296. if (b == Biome.PLAINS) {
  297.  
  298. String s = "+17";
  299. return s;
  300. }
  301.  
  302. if (b == Biome.RIVER) {
  303.  
  304. String s = "+16";
  305. return s;
  306. }
  307.  
  308. if (b == Biome.ROOFED_FOREST) {
  309.  
  310. String s = "+16";
  311. return s;
  312. }
  313.  
  314. if (b == Biome.ROOFED_FOREST_MOUNTAINS) {
  315.  
  316. String s = "+17";
  317. return s;
  318. }
  319.  
  320. if (b == Biome.SAVANNA) {
  321.  
  322. String s = "+25";
  323. return s;
  324. }
  325.  
  326. if (b == Biome.SAVANNA_MOUNTAINS) {
  327.  
  328. String s = "+26";
  329. return s;
  330. }
  331.  
  332. if (b == Biome.SAVANNA_PLATEAU) {
  333.  
  334. String s = "+24";
  335. return s;
  336. }
  337.  
  338. if (b == Biome.SAVANNA_PLATEAU_MOUNTAINS) {
  339.  
  340. String s = "+25";
  341. return s;
  342. }
  343.  
  344. if (b == Biome.SKY) {
  345.  
  346. String s = "0";
  347. return s;
  348. }
  349.  
  350. if (b == Biome.SMALL_MOUNTAINS) {
  351.  
  352. String s = "-19";
  353. return s;
  354. }
  355.  
  356. if (b == Biome.STONE_BEACH) {
  357.  
  358. String s = "+5";
  359. return s;
  360. }
  361.  
  362. if (b == Biome.SUNFLOWER_PLAINS) {
  363.  
  364. String s = "+16";
  365. return s;
  366. }
  367.  
  368. if (b == Biome.SWAMPLAND) {
  369.  
  370. String s = "+13";
  371. return s;
  372. }
  373.  
  374. if (b == Biome.SWAMPLAND_MOUNTAINS) {
  375.  
  376. String s = "+12";
  377. return s;
  378. }
  379.  
  380. if (b == Biome.TAIGA) {
  381.  
  382. String s = "-17";
  383. return s;
  384. }
  385.  
  386. if (b == Biome.TAIGA_HILLS) {
  387.  
  388. String s = "-18";
  389. return s;
  390. }
  391.  
  392. if (b == Biome.TAIGA_MOUNTAINS) {
  393.  
  394. String s = "-16";
  395. return s;
  396. }
  397. }
  398. return null;
  399. }
  400. }
Add Comment
Please, Sign In to add comment