If a blocked command is used, ex. /rename badword or player tries to rename the item in the anvil with 'badword' and it is specified as blacklisted - the action will be denied. It checks if the rename text matches or contains blacklisted word, so if ex. player tries to rename to 'beforebadwordafter' it will still be denied.
Code (YAML):
M0-AntiAnvilRename:
ConfigReloaded: '&aConfig has been reloaded.'
NoPermission: '&cYou do not have permission to use this command.'
RenameBlocked: '&4You cannot rename items.'
CloseOnAttempt: true
EnableWhitelist: false
OnlyWithLore:
Enabled: false
Message: '&4You cannot rename this item.'
AllowedItems: - 'DIAMOND_SWORD'
EnableBlacklist: false
DeniedItems: - 'TRIPWIRE_HOOK'
DenyWhileHolding:
Items: - 'DIAMOND_SWORD'
Commands: - '/rename'
Message: '&4You cannot use this command while holding this item.'
WordBlacklist: -
"badword" -
"otherbadword"