mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-26 07:06:44 +01:00
Configurable help categories
This commit is contained in:
parent
4152582ae0
commit
11689bf855
@ -1,58 +1,50 @@
|
|||||||
package com.github.intellectualsites.plotsquared.plot.commands;
|
package com.github.intellectualsites.plotsquared.plot.commands;
|
||||||
|
|
||||||
|
import com.github.intellectualsites.plotsquared.plot.config.Captions;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* CommandCategory.
|
* CommandCategory.
|
||||||
*/
|
*/
|
||||||
public enum CommandCategory {
|
@RequiredArgsConstructor public enum CommandCategory {
|
||||||
/**
|
/**
|
||||||
* Claiming CommandConfig.
|
* Claiming CommandConfig.
|
||||||
* Such as: /plot claim
|
* Such as: /plot claim
|
||||||
*/
|
*/
|
||||||
CLAIMING("Claiming"), /**
|
CLAIMING(Captions.COMMAND_CATEGORY_CLAIMING), /**
|
||||||
* Teleportation CommandConfig.
|
* Teleportation CommandConfig.
|
||||||
* Such as: /plot visit
|
* Such as: /plot visit
|
||||||
*/
|
*/
|
||||||
TELEPORT("Teleport"), /**
|
TELEPORT(Captions.COMMAND_CATEGORY_TELEPPORT), /**
|
||||||
* Protection.
|
* Protection.
|
||||||
*/
|
*/
|
||||||
SETTINGS("Protection"), /**
|
SETTINGS(Captions.COMMAND_CATEGORY_SETTINGS), /**
|
||||||
* Chat.
|
* Chat.
|
||||||
*/
|
*/
|
||||||
CHAT("Chat"), /**
|
CHAT(Captions.COMMAND_CATEGORY_CHAT), /**
|
||||||
* Web.
|
* Web.
|
||||||
*/
|
*/
|
||||||
SCHEMATIC("Web"), /**
|
SCHEMATIC(Captions.COMMAND_CATEGORY_SCHEMATIC), /**
|
||||||
* Cosmetic.
|
* Cosmetic.
|
||||||
*/
|
*/
|
||||||
APPEARANCE("Cosmetic"), /**
|
APPEARANCE(Captions.COMMAND_CATEGORY_APPEARANCE), /**
|
||||||
* Information CommandConfig.
|
* Information CommandConfig.
|
||||||
* Such as: /plot info
|
* Such as: /plot info
|
||||||
*/
|
*/
|
||||||
INFO("Info"), /**
|
INFO(Captions.COMMAND_CATEGORY_INFO), /**
|
||||||
* Debug CommandConfig.
|
* Debug CommandConfig.
|
||||||
* Such as: /plot debug
|
* Such as: /plot debug
|
||||||
*/
|
*/
|
||||||
DEBUG("Debug"), /**
|
DEBUG(Captions.COMMAND_CATEGORY_DEBUG), /**
|
||||||
* Administration commands.
|
* Administration commands.
|
||||||
*/
|
*/
|
||||||
ADMINISTRATION("Admin");
|
ADMINISTRATION(Captions.COMMAND_CATEGORY_ADMINISTRATION);
|
||||||
/**
|
/**
|
||||||
* The category name (Readable).
|
* The category name (Readable).
|
||||||
*/
|
*/
|
||||||
private final String name;
|
private final Captions caption;
|
||||||
|
|
||||||
/**
|
|
||||||
* Constructor.
|
|
||||||
*
|
|
||||||
* @param name readable name
|
|
||||||
*/
|
|
||||||
CommandCategory(String name) {
|
|
||||||
this.name = name;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@Override public String toString() {
|
@Override public String toString() {
|
||||||
return this.name;
|
return this.caption.s();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -844,6 +844,17 @@ public enum Captions {
|
|||||||
"$2Total bucket values add up to 1 or more. Blocks without a spcified chance will be ignored",
|
"$2Total bucket values add up to 1 or more. Blocks without a spcified chance will be ignored",
|
||||||
"Generator_Bucket"),
|
"Generator_Bucket"),
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Command Categories
|
||||||
|
*/
|
||||||
|
COMMAND_CATEGORY_CLAIMING("Claiming", "Category"), COMMAND_CATEGORY_TELEPPORT("Teleport",
|
||||||
|
"Category"), COMMAND_CATEGORY_SETTINGS("Protection", "Category"), COMMAND_CATEGORY_CHAT(
|
||||||
|
"Chat", "Category"), COMMAND_CATEGORY_SCHEMATIC("Web",
|
||||||
|
"Category"), COMMAND_CATEGORY_APPEARANCE("Cosmetic", "Category"), COMMAND_CATEGORY_INFO(
|
||||||
|
"Info", "Category"), COMMAND_CATEGORY_DEBUG("Debug",
|
||||||
|
"Category"), COMMAND_CATEGORY_ADMINISTRATION("Admin", "Category"),
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Direction
|
* Direction
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user