I have tried to create a mute command and have tried other people's as well, but nothing seems to be working. Hopefully someone can help me with this.
code_language.skript:
command /mute <player> <text>:
permission: ON.mute
permission message: {@PM}
usage: /mute <player> <reason>
trigger:
set {_message} to arg 2
if arg 1 is not set:
message "&cYou must specify a player!" to the player
if arg 2 is not set:
message "&cYou must add a reason why this player should be muted!" to the player
if arg 1 is set:
if arg 2 is set:
set {mute.%arg 1%} to arg 1
message "&c%{mute.%arg 1%}% &6has been muted for the reason: &c%{_message}%"
command /unmute <player>:
permission: ON.mute
permission message: {@PM}
usage: /unmute <player>
trigger:
if arg 1 is not set:
message "You must specify a player to be unmuted."
if arg 1 is set:
set {mute.%arg 1%} to arg 1
message "&6You have unmuted %arg 1%"
on chat:
if {mute.%arg 1%} is set:
cancel event