Advertisement
SUPERFIRE777

アスレチックシステム/採掘さば

Dec 6th, 2019
187
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.30 KB | None | 0 0
  1. function translateTimespan(timespan: timespan) :: text:
  2. set {_result} to "%{_timespan}%"
  3. replace all "seconds" and "second" with "秒" in {_result}
  4. replace all "minutes" and "minute" with "分" in {_result}
  5. replace all "hours" and "hour" with "時間" in {_result}
  6. replace all "days" and "day" with "日" in {_result}
  7. replace all "and" with "" in {_result}
  8. replace all " " with "" in {_result}
  9. return {_result}
  10.  
  11. on walk on redstone block:
  12. set {%player%.playing} to true
  13. set {%player%.start} to now
  14. set {%player%.checkpoint} to player's location
  15. message "&c&lスタート!" to the player
  16.  
  17. on walk on diamond block:
  18. if {%player%.playing} is true:
  19. set {%player%.checkpoint} to player's location
  20. message "&b&lチェックポイントを通過しました!" to the player
  21. message "&b&l通過タイム: %translateTimespan(difference between now and {%player%.start})%"
  22.  
  23. on walk on gold block:
  24. if {%player%.playing} is true:
  25. set {%player%.playing} to false
  26. message "&6&lゴール!" to the player
  27. message "&6&lタイム: %translateTimespan(difference between now and {%player%.start})%"
  28.  
  29. on right click with blaze powder:
  30. if {%player%.playing} is true:
  31. teleport player to {%player%.checkpoint}
  32. message "&4&lチェックポイントに戻しました!" to the player
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement