Rephrase message if user has no access to sub-command help pages

This commit is contained in:
NotMyFault 2021-05-19 23:48:32 +02:00
parent eb9d7e97d9
commit 9c59bfde52
No known key found for this signature in database
GPG Key ID: 158F5701A6AAD00C
2 changed files with 2 additions and 1 deletions

View File

@ -53,7 +53,7 @@ public class HelpPage {
public void render(PlotPlayer<?> player) {
if (this.helpObjects.size() < 1) {
player.sendMessage(TranslatableCaption.of("invalid.not_valid_number"), Template.of("value", "(0)"));
player.sendMessage(TranslatableCaption.of("help.no_permission"));
} else {
Template header = Template.of("header", TranslatableCaption.of("help.help_header").getComponent(player));
Template page_header = Template.of(

View File

@ -404,6 +404,7 @@
"help.help_item": "<gold><usage> <gray>[<gold><alias></gold>]</gray>\n <dark_gray>- </dark_gray><gray><desc></gray>\n",
"help.help_display_all_commands": "<prefix><gray>Display all commands.</gray>",
"help.direction": "<prefix><gold>Current direction: </gold><gray><dir></gray>",
"help.no_permission": "<prefix><red>You have no permission to access commands of that sub category, hence you cannot access the help page.</red>",
"category.command_category_claiming": "<gray>Claiming</gray>",
"category.command_category_teleport": "<gray>Teleport</gray>",
"category.command_category_settings": "<gray>Protection</gray>",