PDCommandBlocker is a plugin that allows you to block specific commands on your server. It provides a set of commands to manage the blocked commands and their permissions.
Commands and Permissions /blocker help Usage: /blocker help
Permission: None
Description: Displays the help message.
/blocker add <command> <permission> Usage: /blocker add <command> <permission>
Permission: blocker.add
Description: Adds a command to the blocker list with the specified permission.
/blocker remove <command> Usage: /blocker remove <command>
Permission: blocker.remove
Description: Removes a command from the blocker list.
/blocker reload Usage: /blocker reload
Permission: blocker.reload
Description: Reloads the plugin configuration and messages.
/blocker list Usage: /blocker list
Permission: blocker.list
Description: Lists all blocked commands.
Configuration (config.yml)
Code (YAML):
default: message: '&cYou do not have permission to use this command.'
permission: '*'
messages:
help:
sound: 'ENTITY_VILLAGER_NO'
permission: ''
message-list: - '&7&m
----------------------------------------'
- '&6&lHelp'
- '&6/blocker help &7- &fShows this message'
- '&6/blocker add <command> &7- &fBlocks a command'
- '&6/blocker remove <command> &7- &fRemoves a command'
- '&6/blocker reload &7- &fReloads the configuration'
- '&6/blocker list &7- &fLists
all blocked commands'
- '&7&m
----------------------------------------'
add:
sound: 'ENTITY_PLAYER_LEVELUP'
permission: 'blocker.add'
message-list: - '&7&m
----------------------------------------'
- '&6&lCommand is now blocked'
- '&7&m
----------------------------------------'
remove:
sound: 'ENTITY_PLAYER_LEVELUP'
permission: 'blocker.remove'
message-list: - '&7&m
----------------------------------------'
- '&6&lCommand is now removed'
- '&7&m
----------------------------------------'
reload:
sound: 'ENTITY_PLAYER_LEVELUP'
permission: 'blocker.reload'
message-list: - '&7&m
----------------------------------------'
- '&6&lConfiguration reloaded'
- '&7&m
----------------------------------------'
list:
sound: 'ENTITY_PLAYER_LEVELUP'
permission: 'blocker.list'
no-commands: '&cThere are
no blocked commands.'
message-list: - '&7&m
----------------------------------------'
- '&6&lBlocked Commands'
- '&6
{command_blocked
}{command_permission
}'
- '&7&m
----------------------------------------'
commands:
help:
no-perm-message: '&cYou do not have permission to use this command.'
permission: '
{defaultperm
}'
add:
no-perm-message: '&cYou do not have permission to use this command.'
permission: 'blocker.add'
remove:
no-perm-message: '&cYou do not have permission to use this command.'
permission: 'blocker.remove'
reload:
no-perm-message: '&cYou do not have permission to use this command.'
permission: 'blocker.reload'
list:
no-perm-message: '&cYou do not have permission to use this command.'
permission: 'blocker.list'
Code (YAML):
commands:
help:
custom-message: '
{defaultmsg
}'
# will be the main message in the config.yml permission: '
{defaultperm
}'
# will be the main permission in the config.yml
Installation Download the plugin jar file.
Place the jar file in your server's plugins directory.
Start your server to generate the configuration files.
Edit the config.yml and blocked_commands.yml files to your liking.
Reload or restart your server to apply the changes