Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command /filter [<text>]:
- trigger:
- if player has permission "filtermsg":
- if arg-1 is set:
- if {blockedwords::%arg-1%} is set:
- Message "&8[&eSmokePVP&8] &cThis word is already added!"
- stop
- if {blockedwords::%arg-1%} is not set:
- set {blockedwords::%arg-1%} to true
- Message "&aSuccess!"
- stop
- on chat:
- if message contains {blockedwords::*}:
- cancel event
- add 1 to {w.%player%}
- set {warnedplayer.%player%} to player
- Message "&cPlease do not swear! you have &c%{w.%player%}% &cout of 5 warnings"
- if {w.%player%} is 5:
- reset {w.%player%}
- add 1 to {mutes.%player%}
- if {mutes.%player%} is 1:
- execute console command "mute %player% 12h Innapropiate Language"
- stop
- if {mutes.%player%} is 2:
- execute console command "mute %player% 2d Innapropiate Language (2nd mute)"
- stop
- #Continue from here
- if {w.%player%} is less than 5:
- log "yeah boiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii"
- loop all players:
- if loop-player has permission "filter.notify":
- Message "&3&lCHAT FILTER &8>> &7%{warnedplayer.%player%}% has swore! Message: %message%" to loop-player
Add Comment
Please, Sign In to add comment