Advertisement
Guest User

Untitled

a guest
Sep 22nd, 2019
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.27 KB | None | 0 0
  1. command /sell:
  2. aliases: s, sellall, esell
  3. trigger:
  4. set {_stone} to amount of stone in player's inventory
  5. set {_coal} to amount of coal in player's inventory
  6. set {_iron} to amount of iron ingot in player's inventory
  7. set {_gold} to amount of gold ingot in player's inventory
  8. set {_diamond} to amount of diamond in player's inventory
  9. set {_emerald} to amount of emerald in player's inventory
  10. add {stoneinbackpack.%player%} to {_stone}
  11. add {coalinbackpack.%player%} to {_coal}
  12. add {ironinbackpack.%player%} to {_iron}
  13. add {goldinbackpack.%player%} to {_gold}
  14. add {diamondinbackpack.%player%} to {_diamond}
  15. add {emeraldinbackpack.%player%} to {_emerald}
  16. set {_amountsold} to {_stone}
  17. add {_coal} to {_amountsold}
  18. add {_iron} to {_amountsold}
  19. add {_gold} to {_amountsold}
  20. add {_diamond} to {_amountsold}
  21. add {_emerald} to {_amountsold}
  22. set {itemsinbackpack.%player%} to 0
  23. set {stoneinbackpack.%player%} to 0
  24. set {coalinbackpack.%player%} to 0
  25. set {ironinbackpack.%player%} to 0
  26. set {goldinbackpack.%player%} to 0
  27. set {diamondinbackpack.%player%} to 0
  28. set {emeraldinbackpack.%player%} to 0
  29. remove 2304 stone from the player's inventory
  30. remove 2304 coal from the player's inventory
  31. remove 2304 iron ingot from the player's inventory
  32. remove 2304 gold ingot from the player's inventory
  33. remove 2304 diamond from the player's inventory
  34. remove 2304 emerald from the player's inventory
  35. set {_global} to difference between {global.multiplier.sell.timeleft} and now
  36. set {_moneyearned} to {_stone}*{@StonePrice}*{multiplier.sell.global}*{multiplier.donor.%player%}*{multiplier.merchant.%player%}
  37. add {_coal}*{@CoalPrice}*{multiplier.sell.%player%}*{multiplier.donor.%player%}*{multiplier.merchant.%player%} to {_moneyearned}
  38. add {_iron}*{@IronPrice}*{multiplier.sell.%player%}*{multiplier.donor.%player%}*{multiplier.merchant.%player%} to {_moneyearned}
  39. add {_gold}*{@GoldPrice}*{multiplier.sell.%player%}*{multiplier.donor.%player%}*{multiplier.merchant.%player%} to {_moneyearned}
  40. add {_diamond}*{@DiamondPrice}*{multiplier.sell.%player%}*{multiplier.donor.%player%}*{multiplier.merchant.%player%} to {_moneyearned}
  41. add {_emerald}*{@EmeraldPrice}*{multiplier.sell.%player%}*{multiplier.donor.%player%}*{multiplier.merchant.%player%} to {_moneyearned}
  42. set {_multi} to {multiplier.donor.%player%}*{multiplier.merchant.%player%}*{multiplier.sell.%player%}
  43. if {multiplier.sell.global} is greater than 1:
  44. set {_moneyearned} to {_moneyearned}*{multiplier.sell.global}
  45. add {_moneyearned} to the player's money
  46. set the player's action bar to "&7Sold &a%{_amountsold}% &7Items for &f$&a%{_moneyearned}% &a&l(*%{_multi}%) &c%{multiplier.sell.global}%x Global Multiplier by &a%{boosteruser}% &7For &a%difference between {_global} and {sell.multi.global.time}%"
  47. else:
  48. add {_moneyearned} to the player's money
  49. set the player's action bar to "&7Sold &a%{_amountsold}% &7Items for &f$&a%{_moneyearned}% &a&l(*%{_multi}%)"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement