Advertisement
kama6012

@everyone in minecraft

Aug 18th, 2018
1,163
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.23 KB | None | 0 0
  1. on chat:
  2. first 1 characters of message is "@"
  3. if {MentionCooltime::%player%} < 0:
  4. if message contains "@everyone" or "@here":
  5. set message to "&l%message%"
  6. wait 1 tick
  7. loop all players:
  8. {mute::%loop-player%} isn't true
  9. play sound "BLOCK_ANVIL_PLACE" to player with volume 1 and pitch 1
  10. set {MentionCooltime::%player%} to 60
  11. else if first 8 characters of message is "@someone":
  12. set {_text} to subtext of message from characters 10 to length of message
  13. set {_someone} to random player out of all players
  14. if {_text} isn't set:
  15. set {_text} to ""
  16. set message to "&7&l@%{_someone}%&r %{_text}%"
  17. wait 1 tick
  18. if {mute::%{_someone}%} isn't true:
  19. play sound "BLOCK_ANVIL_PLACE" to {_someone} with volume 1 and pitch 1
  20. set {MentionCooltime::%player%} to 0
  21. else:
  22. set {_loop} to 0
  23. loop 200 times:
  24. set {_loop} to {_loop} + 1
  25. subtext of message from characters {_loop} to {_loop} is " "
  26. exit this loop
  27. set {_loop} to {_loop} - 1
  28. set {_name} to subtext of message from characters 2 to {_loop}
  29. wait 1 tick
  30. message "&7[Mention]%{_name}%にメンションを送りました。"
  31. if {mute::%{_name}%} isn't true:
  32. play sound "BLOCK_ANVIL_PLACE" to {_name} parsed as player with volume 1 and pitch 1
  33. set {MentionCooltime::%player%} to 0
  34. else:
  35. message "&7[Mention]クールダウン中です!あと%{MentionCooltime::%player%}%秒"
  36.  
  37. command /mutemention:
  38. trigger:
  39. if {mute::%player%} is true:
  40. set {mute::%player%} to false
  41. message "&7[Mention]メンションのミュートをやめました。"
  42. else:
  43. set {mute::%player%} to true
  44. message "&7[Mention]メンションをミュートしました。解除にはもう一度このコマンドを入力してください。"
  45.  
  46. every second:
  47. loop all players:
  48. set {MentionCooltime::%loop-player%} to {MentionCooltime::%loop-player%} - 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement