MostFunGuy

Untitled

Jan 24th, 2014
128
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.80 KB | None | 0 0
  1. #
  2. # Maeyrl's skript
  3. #
  4. #
  5.  
  6. on place:
  7. if tool is redstone block:
  8. if lore of player's tool contains "health":
  9. set {kitlocations::%block's location%} to the block's location
  10. set {kitplayer::%block's location%} to the player
  11. set {kitplayername::%block's location%} to the player's display name
  12. send "<yellow>Success!"
  13.  
  14. command /health:
  15. permission: rankspank.mod
  16. trigger:
  17. if tool is red wool:
  18. set lore of tool to "health"
  19. else:
  20. send "This only works when holding red wool!"
  21.  
  22. on click:
  23. if block is redstone block:
  24. if {kitlocations::%block's location%} is set:
  25. if the player can hold 1 soup:
  26. set the block to iron block
  27. set the data value of the block to 14
  28. set {health.timeslot::%block's location%} to now
  29. set {health.location::%block's location%} to the block's location
  30. set {health.blocktype::%block's location%} to redstone block
  31. set {health.blockdata::%block's location%} to 14
  32. set {_randomitem} to a random integer between 1 and 2
  33. if {_randomitem} is 1:
  34. give player 1 mushroom soup
  35. else if {_randomitem} is 2:
  36. give player 2 mushroom soup
  37. else:
  38. message "You can't hold your soup!" to player
  39. stop
  40.  
  41. every 3 seconds:
  42. loop {health.location::*}:
  43. if difference between now and {health.timeslot::%loop-value%} is more than 15 seconds:
  44. set the block at the loop-value to {health.blocktype::%loop-value%}
  45. set the data value of the block at loop-value to {health.blocktype::%loop-value%}
  46. clear {health.timeslot::%loop-value%}
  47. clear {health.location::%loop-value%}
  48. clear {health.blocktype::%loop-value%}
  49. clear {health.blockdata::%loop-value%}
Advertisement
Add Comment
Please, Sign In to add comment