What This Skript Does
This script is a chat word filter system for a Minecraft server using Skript. It prevents players from sending messages containing blocked words. It also provides commands to manage the list of blocked words.
Main Features
Filter Chat Messages: Automatically scans player messages for blocked words and takes action if a blocked word is found.
Cancels the message (if configured).
Notifies the player with a warning message and sound.
Preloaded Word List: Comes with a default list of blocked words (preloaded-words option).
Customizable Behavior:
enable-filter: Enable or disable word filtering.
use-default-list: Choose whether to use the default word list.
block-notify: Decide if messages with bad words should be canceled or just warned.
Command for Managing the Word List:
Add, remove, or view the list of blocked words.
Available Commands
1. /wordfilter
Usage: /wordfilter
Description: Displays a help menu for the Word Filter system.
Output:
Shows instructions for adding, deleting, or viewing blocked words.
Example:
sql
Copy code
CHAT → Word Filter Management:
Usage: /wordfilter add hi
Description: Adds a word to the blocked words list.
Output:
If successful: CHAT → The word 'hi' has been added to the filter.
If already added: CHAT → The word 'hi' is already blocked.
3. /wordfilter delete <word>
Usage: /wordfilter delete hi
Description: Removes a word from the blocked words list.
Output:
If successful: CHAT → The word 'hi' has been removed from the filter.
If not found: CHAT → The word 'hi' is not in the blocked list.
4. /wordfilter show
Usage: /wordfilter show
Description: Displays the list of currently blocked words.
Output:
If no blocked words: CHAT → There are no words currently blocked.
If words exist: CHAT → Blocked words: hi, bye, badword
Permissions
filter.manage: Required to use /wordfilter commands. If a player lacks this permission, they will see:
Access denied! This command is restricted.
This script is a chat word filter system for a Minecraft server using Skript. It prevents players from sending messages containing blocked words. It also provides commands to manage the list of blocked words.
Main Features
Filter Chat Messages: Automatically scans player messages for blocked words and takes action if a blocked word is found.
Cancels the message (if configured).
Notifies the player with a warning message and sound.
Preloaded Word List: Comes with a default list of blocked words (preloaded-words option).
Customizable Behavior:
enable-filter: Enable or disable word filtering.
use-default-list: Choose whether to use the default word list.
block-notify: Decide if messages with bad words should be canceled or just warned.
Command for Managing the Word List:
Add, remove, or view the list of blocked words.
Available Commands
1. /wordfilter
Usage: /wordfilter
Description: Displays a help menu for the Word Filter system.
Output:
Shows instructions for adding, deleting, or viewing blocked words.
Example:
sql
Copy code
CHAT → Word Filter Management:
- /wordfilter add <word> : Add a word to the blocked list
- /wordfilter delete <word> : Remove a word from the blocked list
- /wordfilter show : View all blocked words
Usage: /wordfilter add hi
Description: Adds a word to the blocked words list.
Output:
If successful: CHAT → The word 'hi' has been added to the filter.
If already added: CHAT → The word 'hi' is already blocked.
3. /wordfilter delete <word>
Usage: /wordfilter delete hi
Description: Removes a word from the blocked words list.
Output:
If successful: CHAT → The word 'hi' has been removed from the filter.
If not found: CHAT → The word 'hi' is not in the blocked list.
4. /wordfilter show
Usage: /wordfilter show
Description: Displays the list of currently blocked words.
Output:
If no blocked words: CHAT → There are no words currently blocked.
If words exist: CHAT → Blocked words: hi, bye, badword
Permissions
filter.manage: Required to use /wordfilter commands. If a player lacks this permission, they will see:
Access denied! This command is restricted.