Advertisement
Guest User

Untitled

a guest
Sep 3rd, 2015
222
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.51 KB | None | 0 0
  1. package com.gmail.val59000mc.villagerapi;
  2.  
  3. import org.bukkit.inventory.ItemStack;
  4.  
  5. public final class VillagerTrade
  6. {
  7.  
  8.  
  9. private ItemStack primaryItem;
  10. private ItemStack secondaryItem;
  11. private ItemStack rewardItem;
  12.  
  13.  
  14. public VillagerTrade(final ItemStack primaryItem, final ItemStack secondaryItem, final ItemStack rewardItem)
  15. {
  16. this.primaryItem = secondaryItem;
  17. this.secondaryItem = secondaryItem;
  18. this.rewardItem = rewardItem;
  19. }
  20.  
  21.  
  22. public VillagerTrade(final ItemStack primarySlot, final ItemStack rewardItem)
  23. {
  24. this.primaryItem = primarySlot;
  25. this.rewardItem = rewardItem;
  26. }
  27.  
  28.  
  29. @Deprecated
  30. public static boolean hasItem2(final VillagerTrade villagerTrade)
  31. {
  32. return villagerTrade.secondaryItem != null;
  33. }
  34.  
  35.  
  36. public static boolean hasSecondaryItem(final VillagerTrade villagerTrade)
  37. {
  38. return villagerTrade.secondaryItem != null;
  39. }
  40.  
  41.  
  42. @Deprecated
  43. public static ItemStack getItem1(final VillagerTrade villagerTrade)
  44. {
  45. return villagerTrade.secondaryItem;
  46. }
  47.  
  48.  
  49. public static ItemStack getPrimaryItem(final VillagerTrade villagerTrade)
  50. {
  51. return villagerTrade.primaryItem;
  52. }
  53.  
  54.  
  55. @Deprecated
  56. public static ItemStack getItem2(final VillagerTrade villagerTrade)
  57. {
  58. return villagerTrade.secondaryItem;
  59. }
  60.  
  61.  
  62. public static ItemStack getSecondaryItem(final VillagerTrade villagerTrade)
  63. {
  64. return villagerTrade.secondaryItem;
  65. }
  66.  
  67.  
  68. public static ItemStack getRewardItem(final VillagerTrade villagerTrade)
  69. {
  70. return villagerTrade.rewardItem;
  71. }
  72.  
  73.  
  74. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement