TheRecovery

Untitled

Feb 24th, 2014
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 18.78 KB | None | 0 0
  1. package me.TheRecovery007.walmain;
  2.  
  3. import java.util.Arrays;
  4.  
  5. import me.TheRecovery007.walmain.Settings.PreMade;
  6.  
  7. import org.bukkit.Bukkit;
  8. import org.bukkit.ChatColor;
  9. import org.bukkit.Material;
  10. import org.bukkit.entity.HumanEntity;
  11. import org.bukkit.entity.Player;
  12. import org.bukkit.event.EventHandler;
  13. import org.bukkit.event.Listener;
  14. import org.bukkit.event.inventory.InventoryClickEvent;
  15. import org.bukkit.inventory.Inventory;
  16. import org.bukkit.inventory.ItemStack;
  17. import org.bukkit.inventory.meta.ItemMeta;
  18. import org.bukkit.material.Wool;
  19. import org.bukkit.plugin.Plugin;
  20.  
  21. public class Menu implements Listener {
  22.  
  23.  
  24. private Inventory inv;
  25. PreMade pre = PreMade.getInstance();
  26. private Inventory hats;
  27. private Inventory clothes;
  28. private Inventory remove;
  29. private ItemStack web, vote, vip, s, a, g, d, an, re, l, dis, cloth, leatherc, chainc, ironc, goldc, diac, leatherp, chainp, ironp, goldp, leatherb, chainb, ironb, goldb, diab, diapants, removec, removep;
  30.  
  31. public Menu(Plugin p) {
  32. inv = Bukkit.getServer().createInventory(null, 18, ChatColor.DARK_GRAY + "- " + ChatColor.GREEN + "! " + ChatColor.DARK_GRAY + "Player Menu" + ChatColor.GREEN + " !" + ChatColor.DARK_GRAY + " -");
  33. hats = Bukkit.getServer().createInventory(null, 27, ChatColor.DARK_GRAY + "- " + ChatColor.GREEN + "! " + ChatColor.DARK_GRAY + "Hat Menu" + ChatColor.GREEN + " !" + ChatColor.DARK_GRAY + " -");
  34. clothes = Bukkit.getServer().createInventory(null, 27, ChatColor.DARK_GRAY + "- " + ChatColor.GREEN + "! " + ChatColor.DARK_GRAY + "Cloth Menu" + ChatColor.GREEN + " !" + ChatColor.DARK_GRAY + " -");
  35. remove = Bukkit.getServer().createInventory(null, 27, ChatColor.DARK_GRAY + "- " + ChatColor.GREEN + "! " + ChatColor.DARK_GRAY + "Remove" + ChatColor.GREEN + " !" + ChatColor.DARK_GRAY + " -");
  36. //w = createItem(Material.DIAMOND_BOOTS, ChatColor.GREEN + "WalkSpeed");
  37. s = createItem(Material.BLAZE_ROD, ChatColor.YELLOW + "Particles");
  38. a = createItem(Material.GLASS, ChatColor.RED + "Hats");
  39. g = createItem(Material.GLASS, ChatColor.RED + "Glass");
  40. d = createItem(Material.DIAMOND_BLOCK, ChatColor.RED + "Diamond");
  41. an = createItem(Material.ANVIL, ChatColor.RED + "Anvil");
  42. re = createItem(Material.NAME_TAG, ChatColor.RED + "Remove");
  43. removec = createItem(Material.NAME_TAG, ChatColor.RED + "RemoveChestPlate");
  44. removep = createItem(Material.NAME_TAG, ChatColor.RED + "RemoveLeggings");
  45. web = createItem(Material.NAME_TAG, ChatColor.RED + "Website");
  46. vote = createItem(Material.NAME_TAG, ChatColor.RED + "Vote");
  47. vip = createItem(Material.NAME_TAG, ChatColor.RED + "Vip");
  48. l = createItem(Material.LEAVES, ChatColor.RED + "Leaves");
  49. dis = createItem(Material.DISPENSER, ChatColor.RED + "Dispenser");
  50. cloth = createItem(Material.CHEST, ChatColor.RED + "Clothes");
  51. leatherc = createItem(Material.LEATHER_CHESTPLATE, ChatColor.RED + " LeatherChest");
  52. chainc = createItem(Material.CHAINMAIL_CHESTPLATE, ChatColor.RED + " ChainChest");
  53. ironc = createItem(Material.IRON_CHESTPLATE, ChatColor.RED + " IronChest");
  54. goldc = createItem(Material.GOLD_CHESTPLATE, ChatColor.RED + " GoldChest");
  55. diac = createItem(Material.DIAMOND_CHESTPLATE, ChatColor.RED + " DiamondChest");
  56. leatherp = createItem(Material.LEATHER_LEGGINGS, ChatColor.RED + " LeatherPants");
  57. chainp = createItem(Material.CHAINMAIL_LEGGINGS, ChatColor.RED + " ChainPants");
  58. ironp = createItem(Material.IRON_LEGGINGS, ChatColor.RED + " IronPants");
  59. goldp = createItem(Material.GOLD_LEGGINGS, ChatColor.RED + " GoldPants");
  60. diapants = createItem(Material.DIAMOND_LEGGINGS, ChatColor.RED + " DiamondPants");
  61. leatherb = createItem(Material.LEATHER_BOOTS, ChatColor.RED + " LeatherBoots");
  62. chainb = createItem(Material.CHAINMAIL_BOOTS, ChatColor.RED + " ChainBoots");
  63. ironb = createItem(Material.IRON_BOOTS, ChatColor.RED + " IronBoots");
  64. goldb = createItem(Material.GOLD_BOOTS, ChatColor.RED + " GoldBoots");
  65. diab = createItem(Material.DIAMOND_BOOTS, ChatColor.RED + " DiamondBoots");
  66.  
  67. inv.setItem(4, s);
  68. inv.setItem(6, a);
  69. inv.setItem(2, cloth);
  70. inv.setItem(9, web);
  71. inv.setItem(11, vote);
  72. inv.setItem(13, vip);
  73.  
  74. clothes.setItem(0, leatherc);
  75. clothes.setItem(1, chainc);
  76. clothes.setItem(2, ironc);
  77. clothes.setItem(3, goldc);
  78. clothes.setItem(4, diac);
  79. clothes.setItem(9, leatherp);
  80. clothes.setItem(10, chainp);
  81. clothes.setItem(11, ironp);
  82. clothes.setItem(12, goldp);
  83. clothes.setItem(13, diapants);
  84. clothes.setItem(18, leatherb);
  85. clothes.setItem(19, chainb);
  86. clothes.setItem(20, ironb);
  87. clothes.setItem(21, goldb);
  88. clothes.setItem(22, diab);
  89. clothes.setItem(16, re);
  90.  
  91. remove.setItem(1, removec);
  92. remove.setItem(2, removep);
  93.  
  94. hats.setItem(0, g);
  95. hats.setItem(1, d);
  96. hats.setItem(2, an);
  97. hats.setItem(3, dis);
  98. hats.setItem(4, l);
  99. hats.setItem(16, re);
  100. Bukkit.getServer().getPluginManager().registerEvents(this, p);
  101. }
  102.  
  103. private ItemStack createItem(Material diamondBoots, String name) {
  104. ItemStack i = new Wool(diamondBoots).toItemStack(1);
  105. ItemMeta im = i.getItemMeta();
  106. im.setDisplayName(name);
  107. i.setItemMeta(im);
  108. return i;
  109. }
  110.  
  111. public void show(Player p) {
  112. p.openInventory(inv);
  113. }
  114. public void hatsopen(HumanEntity humanEntity) {
  115. humanEntity.openInventory(hats);
  116. }
  117. public void clothopen(HumanEntity humanEntity) {
  118. humanEntity.openInventory(clothes);
  119. }
  120.  
  121.  
  122. @EventHandler
  123. public void onInventoryClick(InventoryClickEvent e) {
  124. Player p = (Player) e.getWhoClicked();
  125. if (!e.getInventory().getName().equalsIgnoreCase(inv.getName())) return;
  126. if (e.getCurrentItem().getItemMeta() == null) return;
  127. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("WalkSpeed")) {
  128. e.setCancelled(true);
  129. if (p.getWalkSpeed() == 0.3F)
  130. p.setWalkSpeed(0.6F);
  131. else if (p.getWalkSpeed() == 0.6F)
  132. p.setWalkSpeed(0.3F);
  133. e.getWhoClicked().closeInventory();
  134. }
  135. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Particles")) {
  136. e.setCancelled(true);
  137. e.getWhoClicked().closeInventory();
  138. }
  139. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Hats")) {
  140. e.setCancelled(true);
  141. hatsopen(e.getWhoClicked());
  142. }
  143. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Clothes")) {
  144. e.setCancelled(true);
  145. clothopen(e.getWhoClicked());
  146. }
  147. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Website")) {
  148. e.setCancelled(true);
  149. p.sendMessage(pre.prefix + ChatColor.DARK_GRAY + "www.Wal-Craft.info");
  150. e.getWhoClicked().closeInventory();
  151. }
  152. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Vote")) {
  153. e.setCancelled(true);
  154. p.sendMessage(pre.prefix + ChatColor.DARK_GRAY + "www.Wal-Craft.info/vote");
  155. e.getWhoClicked().closeInventory();
  156. }
  157. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Vip")) {
  158. e.setCancelled(true);
  159. p.sendMessage(pre.prefix + ChatColor.DARK_GRAY + "www.Wal-Craft.info/vip");
  160. e.getWhoClicked().closeInventory();
  161. }
  162.  
  163. }
  164. @EventHandler
  165. public void onInventoryClickhats(InventoryClickEvent e) {
  166. Player p = (Player) e.getWhoClicked();
  167. if (!e.getInventory().getName().equalsIgnoreCase(hats.getName())) return;
  168. if (e.getCurrentItem().getItemMeta() == null) return;
  169. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Glass")) {
  170. e.setCancelled(true);
  171. p.getInventory().setHelmet(glass());
  172. e.getWhoClicked().closeInventory();
  173. }
  174. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Anvil")) {
  175. e.setCancelled(true);
  176. p.getInventory().setHelmet(anvil());
  177. e.getWhoClicked().closeInventory();
  178. }
  179. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Diamond")) {
  180. e.setCancelled(true);
  181. p.getInventory().setHelmet(dia());
  182. e.getWhoClicked().closeInventory();
  183. }
  184. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Leaves")) {
  185. e.setCancelled(true);
  186. p.getInventory().setHelmet(leaves());
  187. e.getWhoClicked().closeInventory();
  188. }
  189. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Dispenser")) {
  190. e.setCancelled(true);
  191. p.getInventory().setHelmet(dis());
  192. e.getWhoClicked().closeInventory();
  193. }
  194. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Remove")) {
  195. e.setCancelled(true);
  196. p.getInventory().setHelmet(null);
  197. e.getWhoClicked().closeInventory();
  198. }
  199.  
  200. }
  201. @EventHandler
  202. public void onInventoryClickclothes(InventoryClickEvent e) {
  203. Player p = (Player) e.getWhoClicked();
  204. if (!e.getInventory().getName().equalsIgnoreCase(clothes.getName())) return;
  205. if (e.getCurrentItem().getItemMeta() == null) return;
  206. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("LeatherChest")) {
  207. e.setCancelled(true);
  208. p.getInventory().setChestplate(leatherc());
  209. e.getWhoClicked().closeInventory();
  210. }
  211. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("ChainChest")) {
  212. e.setCancelled(true);
  213. p.getInventory().setChestplate(chainc());
  214. e.getWhoClicked().closeInventory();
  215. }
  216. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("DiamondPants")) {
  217. e.setCancelled(true);
  218. p.getInventory().setLeggings(diapants());
  219. e.getWhoClicked().closeInventory();
  220. }
  221. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("IronChest")) {
  222. e.setCancelled(true);
  223. p.getInventory().setChestplate(ironc());
  224. e.getWhoClicked().closeInventory();
  225. }
  226. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("GoldChest")) {
  227. e.setCancelled(true);
  228. p.getInventory().setChestplate(goldc());
  229. e.getWhoClicked().closeInventory();
  230. }
  231. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("DiamondChest")) {
  232. e.setCancelled(true);
  233. p.getInventory().setChestplate(diac());
  234. e.getWhoClicked().closeInventory();
  235. }
  236. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("LeatherPants")) {
  237. e.setCancelled(true);
  238. p.getInventory().setLeggings(leatherp());
  239. e.getWhoClicked().closeInventory();
  240. }
  241. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("ChainPants")) {
  242. e.setCancelled(true);
  243. p.getInventory().setLeggings(chainp());
  244. e.getWhoClicked().closeInventory();
  245. }
  246. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("IronPants")) {
  247. e.setCancelled(true);
  248. p.getInventory().setLeggings(ironp());
  249. e.getWhoClicked().closeInventory();
  250. }
  251. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("GoldPants")) {
  252. e.setCancelled(true);
  253. p.getInventory().setLeggings(goldp());
  254. e.getWhoClicked().closeInventory();
  255. }
  256. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("LeatherBoots")) {
  257. e.setCancelled(true);
  258. p.getInventory().setBoots(leatherb());
  259. e.getWhoClicked().closeInventory();
  260. }
  261. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("ChainBoots")) {
  262. e.setCancelled(true);
  263. p.getInventory().setBoots(chainb());
  264. e.getWhoClicked().closeInventory();
  265. }
  266. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("IronBoots")) {
  267. e.setCancelled(true);
  268. p.getInventory().setBoots(ironb());
  269. e.getWhoClicked().closeInventory();
  270. }
  271. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("GoldBoots")) {
  272. e.setCancelled(true);
  273. p.getInventory().setBoots(goldb());
  274. e.getWhoClicked().closeInventory();
  275. }
  276. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("DiamondBoots")) {
  277. e.setCancelled(true);
  278. p.getInventory().setBoots(diab());
  279. e.getWhoClicked().closeInventory();
  280. }
  281. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("Remove")) {
  282. e.setCancelled(true);
  283. p.getInventory().setChestplate(null);
  284. p.getInventory().setLeggings(null);
  285. e.getWhoClicked().closeInventory();
  286. }
  287. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("RemoveChestPlate")) {
  288. e.setCancelled(true);
  289. p.getInventory().setChestplate(null);
  290. e.getWhoClicked().closeInventory();
  291. }
  292. if (e.getCurrentItem().getItemMeta().getDisplayName().contains("RemoveLeggings")) {
  293. e.setCancelled(true);
  294. p.getInventory().setLeggings(null);
  295. e.getWhoClicked().closeInventory();
  296. }
  297.  
  298. }
  299.  
  300. public ItemStack glass() { ItemStack is = new ItemStack(Material.GLASS);
  301. ItemMeta im = is.getItemMeta();
  302. im.setDisplayName(ChatColor.GRAY + "Hat");
  303. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Glass hat" }));
  304. is.setItemMeta(im);
  305.  
  306. return is;
  307. }
  308. public ItemStack anvil() { ItemStack is = new ItemStack(Material.ANVIL);
  309. ItemMeta im = is.getItemMeta();
  310. im.setDisplayName(ChatColor.GRAY + "Hat");
  311. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Anvil hat" }));
  312. is.setItemMeta(im);
  313.  
  314. return is;
  315. }
  316. public ItemStack dia() { ItemStack is = new ItemStack(Material.DIAMOND_BLOCK);
  317. ItemMeta im = is.getItemMeta();
  318. im.setDisplayName(ChatColor.GRAY + "Hat");
  319. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Diamond hat" }));
  320. is.setItemMeta(im);
  321.  
  322. return is;
  323. }
  324. public ItemStack re() { ItemStack is = new ItemStack(Material.NAME_TAG);
  325. ItemMeta im = is.getItemMeta();
  326. im.setDisplayName(ChatColor.GRAY + "Remove");
  327. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Remove" }));
  328. is.setItemMeta(im);
  329.  
  330. return is;
  331. }
  332. public ItemStack web() { ItemStack is = new ItemStack(Material.NAME_TAG);
  333. ItemMeta im = is.getItemMeta();
  334. im.setDisplayName(ChatColor.GRAY + "Web");
  335. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Web" }));
  336. is.setItemMeta(im);
  337.  
  338. return is;
  339. }
  340. public ItemStack vote() { ItemStack is = new ItemStack(Material.NAME_TAG);
  341. ItemMeta im = is.getItemMeta();
  342. im.setDisplayName(ChatColor.GRAY + "Vote");
  343. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Vote" }));
  344. is.setItemMeta(im);
  345.  
  346. return is;
  347. }
  348. public ItemStack vip() { ItemStack is = new ItemStack(Material.NAME_TAG);
  349. ItemMeta im = is.getItemMeta();
  350. im.setDisplayName(ChatColor.GRAY + "Vip");
  351. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Vip" }));
  352. is.setItemMeta(im);
  353.  
  354. return is;
  355. }
  356. public ItemStack leaves() { ItemStack is = new ItemStack(Material.LEAVES);
  357. ItemMeta im = is.getItemMeta();
  358. im.setDisplayName(ChatColor.GRAY + "Hat");
  359. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Leaves hat" }));
  360. is.setItemMeta(im);
  361.  
  362. return is;
  363. }
  364. public ItemStack leatherc() { ItemStack is = new ItemStack(Material.LEATHER_CHESTPLATE);
  365. ItemMeta im = is.getItemMeta();
  366. im.setDisplayName(ChatColor.GRAY + "ChestPlate");
  367. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Leather ChestPlate" }));
  368. is.setItemMeta(im);
  369.  
  370. return is;
  371. }
  372. public ItemStack chainc() { ItemStack is = new ItemStack(Material.CHAINMAIL_CHESTPLATE);
  373. ItemMeta im = is.getItemMeta();
  374. im.setDisplayName(ChatColor.GRAY + "ChestPlate");
  375. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Chain ChestPlatet" }));
  376. is.setItemMeta(im);
  377.  
  378. return is;
  379. }
  380. public ItemStack ironc() { ItemStack is = new ItemStack(Material.IRON_CHESTPLATE);
  381. ItemMeta im = is.getItemMeta();
  382. im.setDisplayName(ChatColor.GRAY + "ChestPlate");
  383. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Iron ChestPlate" }));
  384. is.setItemMeta(im);
  385.  
  386. return is;
  387. }
  388. public ItemStack goldc() { ItemStack is = new ItemStack(Material.GOLD_CHESTPLATE);
  389. ItemMeta im = is.getItemMeta();
  390. im.setDisplayName(ChatColor.GRAY + "ChestPlate");
  391. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Gold ChestPlatet" }));
  392. is.setItemMeta(im);
  393.  
  394. return is;
  395. }
  396. public ItemStack diac() { ItemStack is = new ItemStack(Material.DIAMOND_CHESTPLATE);
  397. ItemMeta im = is.getItemMeta();
  398. im.setDisplayName(ChatColor.GRAY + "ChestPlate");
  399. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Diamond ChestPlatet" }));
  400. is.setItemMeta(im);
  401.  
  402. return is;
  403. }
  404. public ItemStack leatherp() { ItemStack is = new ItemStack(Material.LEATHER_LEGGINGS);
  405. ItemMeta im = is.getItemMeta();
  406. im.setDisplayName(ChatColor.GRAY + "Leggings");
  407. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Leather Leggings" }));
  408. is.setItemMeta(im);
  409.  
  410. return is;
  411. }
  412. public ItemStack chainp() { ItemStack is = new ItemStack(Material.CHAINMAIL_LEGGINGS);
  413. ItemMeta im = is.getItemMeta();
  414. im.setDisplayName(ChatColor.GRAY + "Leggings");
  415. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Chain Leggings" }));
  416. is.setItemMeta(im);
  417.  
  418. return is;
  419. }
  420. public ItemStack ironp() { ItemStack is = new ItemStack(Material.IRON_LEGGINGS);
  421. ItemMeta im = is.getItemMeta();
  422. im.setDisplayName(ChatColor.GRAY + "Leggings");
  423. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Iron Leggings" }));
  424. is.setItemMeta(im);
  425.  
  426. return is;
  427. }
  428. public ItemStack goldp() { ItemStack is = new ItemStack(Material.GOLD_LEGGINGS);
  429. ItemMeta im = is.getItemMeta();
  430. im.setDisplayName(ChatColor.GRAY + "Leggings");
  431. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Gold Leggings" }));
  432. is.setItemMeta(im);
  433.  
  434. return is;
  435. }
  436. public ItemStack diapants() { ItemStack is = new ItemStack(Material.DIAMOND_LEGGINGS);
  437. ItemMeta im = is.getItemMeta();
  438. im.setDisplayName(ChatColor.GRAY + "Leggings");
  439. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Diamond Leggings" }));
  440. is.setItemMeta(im);
  441.  
  442. return is;
  443. }
  444. public ItemStack leatherb() { ItemStack is = new ItemStack(Material.LEATHER_BOOTS);
  445. ItemMeta im = is.getItemMeta();
  446. im.setDisplayName(ChatColor.GRAY + "Boots");
  447. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Leather Boots" }));
  448. is.setItemMeta(im);
  449.  
  450. return is;
  451. }
  452. public ItemStack chainb() { ItemStack is = new ItemStack(Material.CHAINMAIL_BOOTS);
  453. ItemMeta im = is.getItemMeta();
  454. im.setDisplayName(ChatColor.GRAY + "Boots");
  455. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Chain Boots" }));
  456. is.setItemMeta(im);
  457.  
  458. return is;
  459. }
  460. public ItemStack ironb() { ItemStack is = new ItemStack(Material.IRON_BOOTS);
  461. ItemMeta im = is.getItemMeta();
  462. im.setDisplayName(ChatColor.GRAY + "Boots");
  463. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Iron Boots" }));
  464. is.setItemMeta(im);
  465.  
  466. return is;
  467. }
  468. public ItemStack goldb() { ItemStack is = new ItemStack(Material.GOLD_BOOTS);
  469. ItemMeta im = is.getItemMeta();
  470. im.setDisplayName(ChatColor.GRAY + "Boots");
  471. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Gold Boots" }));
  472. is.setItemMeta(im);
  473.  
  474. return is;
  475. }
  476. public ItemStack diab() { ItemStack is = new ItemStack(Material.DIAMOND_BOOTS);
  477. ItemMeta im = is.getItemMeta();
  478. im.setDisplayName(ChatColor.GRAY + "Boots");
  479. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Diamond Boots" }));
  480. is.setItemMeta(im);
  481.  
  482. return is;
  483. }
  484. public ItemStack dis() { ItemStack is = new ItemStack(Material.DISPENSER);
  485. ItemMeta im = is.getItemMeta();
  486. im.setDisplayName(ChatColor.GRAY + "Hat");
  487. im.setLore(Arrays.asList(new String[] { ChatColor.RED + "Dispenser hat" }));
  488. is.setItemMeta(im);
  489.  
  490. return is;
  491. }
  492. }
Advertisement
Add Comment
Please, Sign In to add comment