SHARE
TWEET

Untitled

a guest Feb 21st, 2019 71 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. variables:
  2.     {schowek.koxy.%player%} = 0
  3.     {schowek.refile.%player%} = 0
  4.     {schowek.perly.%player%} = 0
  5. options:
  6.     namegui:&3&lSCHOWEK
  7.    
  8.     koxy_text: &7Twoj nadmiar koxow zostal przeniesiony do schowka!
  9.     refile_text: &7Twoj nadmiar refili zostal przeniesiony do schowka!
  10.     perly_text: &7Twoj nadmiar perel zostal przeniesiony do schowka!
  11.     full_inventory: &7Nie miales wolnego miejsca w ekwipunku, itemy zostaly wyrzucone na ziemie!
  12.    
  13.     koxy: 1
  14.     refile: 12
  15.     perly: 3
  16.    
  17. on damage of player:
  18.     set {_koxy} to number of golden apple:1 in the victim's inventory
  19.     set {_refile} to number of golden apple:0 in the victim's inventory
  20.     set {_perly} to number of ender pearl in the victim's inventory
  21.     if {_koxy} is more than {@koxy}:
  22.         set {_a} to {_koxy}-{@koxy}
  23.         remove {_a} of golden apple:1 from victim
  24.         add {_a} to {schowek.koxy.%victim%}
  25.         message "{@koxy_text}" to victim
  26.     if {_refile} is more than {@refile}:
  27.         set {_a} to {_refile}-{@refile}
  28.         remove {_a} of golden apple:0 from victim
  29.         add {_a} to {schowek.refile.%victim%}
  30.         message "{@refile_text}" to victim
  31.     if {_perly} is more than {@perly}:
  32.         set {_a} to {_perly}-{@perly}
  33.         remove {_a} of ender pearl from victim
  34.         add {_a} to {schowek.perly.%victim%}
  35.         message "{@perly_text}" to victim
  36.  
  37. command /lipex:schowek [<text>]:
  38.     aliases: /schowek, /depozyt
  39.     trigger:
  40.         open chest with 1 rows named "&3&lSCHOWEK" to player
  41.         set player's current inventory's slot 0 to golden apple:1 named "&f&oKOXY" with lore "&8» &7W schowku: &f%{schowek.koxy.%player%}%&7szt."
  42.         set player's current inventory's slot 1 to golden apple:0 named "&f&oREFILE" with lore "&8» &7W schowku: &f%{schowek.refile.%player%}%&7szt."
  43.         set player's current inventory's slot 2 to ender pearl named "&f&oPERLY" with lore "&8» &7W schowku: &f%{schowek.perly.%player%}%&7szt."
  44.         set player's current inventory's slot 8 to name tag of unbreaking 3 named "&f&oLIMITY" with lore "&8» &7Limit koxow: &f{@koxy}&7szt. ||&8» &7Limit refili: &f{@refile}&7szt. ||&8» &7Limit perel: &f{@perly}&7szt."
  45.  
  46. on inventory click:
  47.     if inventory name of player's current inventory is "&3&lSCHOWEK":
  48.         if clicked slot is 0:
  49.             cancel event
  50.             close player's inventory
  51.             set {_a} to {schowek.koxy.%player%}
  52.             loop {_a} times:
  53.                 remove 1 from {schowek.koxy.%player%}
  54.                 if player can hold 1 golden apple:1:
  55.                     add 1 golden apple:1 to player
  56.                 else:
  57.                     drop 1 golden apple:1 at player
  58.                     message "{@full_inventory}"
  59.         if clicked slot is 1:
  60.             cancel event
  61.             close player's inventory
  62.             set {_a} to {schowek.refile.%player%}
  63.             loop {_a} times:
  64.                 remove 1 from {schowek.refile.%player%}
  65.                 if player can hold 1 golden apple:0:
  66.                     add 1 golden apple:0 to player
  67.                 else:
  68.                     drop 1 golden apple:0 at player
  69.                     message "{@full_inventory}"
  70.         if clicked slot is 2:
  71.             cancel event
  72.             close player's inventory
  73.             set {_a} to {schowek.perly.%player%}
  74.             loop {_a} times:
  75.                 remove 1 from {schowek.perly.%player%}
  76.                 if player can hold 1 ender pearl:
  77.                     add 1 ender pearl to player
  78.                 else:
  79.                     drop 1 ender pearl at player
  80.                     message "{@full_inventory}"
  81.         if clicked slot is 8:
  82.             close player's inventory
  83.     else:
  84.         stop
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top