knugi

Untitled

Nov 12th, 2014
187
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.17 KB | None | 0 0
  1. options:
  2. chanceChest: 50
  3. nameChest: &7&m------&r &6Skrzynka &7&m------
  4.  
  5. chanceKey: 50
  6. nameKey: &7&m------&r &6Klucz &7&m------
  7.  
  8. on mine of stone:
  9. chance of {@chanceChest}%:
  10. give 1 chest named "{@nameChest}" to the player
  11. chance of {@chanceKey}%:
  12. give 1 clock named "{@nameKey}" to the player
  13. on place:
  14. if name of player's tool is "{@nameChest}":
  15. cancel event
  16. send "&6Uzyj klucza."
  17. stop
  18.  
  19.  
  20. on script load:
  21. delete {chest.nagrody::*}
  22.  
  23. add diamond to {chest.nagrody::*}
  24. add dirt to {chest.nagrody::*}
  25. #add nazwa_przedmiotu to {chest.nagrody::*}
  26.  
  27.  
  28.  
  29.  
  30. on rightclick:
  31. if name of player's tool is "{@nameKey}":
  32. if player has chest named "{@nameChest}":
  33. remove 1 chest named "{@nameChest}" from player
  34. remove 1 clock named "{@nameKey}" from player
  35. set {_n} to size of {chest.nagrody::*}
  36. loop {chest.nagrody::*}:
  37. chance of 100 / {_n}%:
  38. give loop-value to the player
  39. exit loop
  40. chance of 100 / {_n}%:
  41. give loop-value to the player
  42. exit loop
  43. chance of 100 / {_n}%:
  44. give loop-value to the player
  45. exit loop
  46. chance of 100 / {_n}%:
  47. give loop-value to the player
  48. exit loop
Advertisement
Add Comment
Please, Sign In to add comment