mirror of
https://github.com/HibiscusMC/HMCCosmetics.git
synced 2025-12-28 19:39:14 +00:00
Added help command
This commit is contained in:
@@ -4,6 +4,7 @@ import io.github.fisher2911.hmccosmetics.HMCCosmetics;
|
||||
import io.github.fisher2911.hmccosmetics.gui.ArmorItem;
|
||||
import io.github.fisher2911.hmccosmetics.gui.CosmeticsMenu;
|
||||
import io.github.fisher2911.hmccosmetics.gui.DyeSelectorGui;
|
||||
import io.github.fisher2911.hmccosmetics.message.Message;
|
||||
import io.github.fisher2911.hmccosmetics.message.MessageHandler;
|
||||
import io.github.fisher2911.hmccosmetics.message.Messages;
|
||||
import io.github.fisher2911.hmccosmetics.user.User;
|
||||
@@ -86,4 +87,18 @@ public class CosmeticsCommand extends CommandBase {
|
||||
}
|
||||
}
|
||||
|
||||
@SubCommand("help") // WORK IN PROGRESS (WIP)
|
||||
@Permission(io.github.fisher2911.hmccosmetics.message.Permission.HELP_COMMAND)
|
||||
public void helpCommand(final CommandSender sender) {
|
||||
Bukkit.getScheduler().runTaskAsynchronously(
|
||||
this.plugin,
|
||||
() -> {
|
||||
this.messageHandler.sendMessage(
|
||||
sender,
|
||||
Messages.HELP_COMMAND
|
||||
);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -18,4 +18,16 @@ public class Messages {
|
||||
new Message("reloaded", "Config reloaded");
|
||||
public static final Message INVALID_TYPE =
|
||||
new Message("invalid-type", "Invalid type");
|
||||
public static final Message HELP_COMMAND =
|
||||
new Message("help-command", "<#6D9DC5><st> </st> <gradient:#40B7D6:#6D9DC5>HMCCosmetics - Help</gradient><#6D9DC5> <st> </st>\n" +
|
||||
"\n" +
|
||||
"\n" +
|
||||
"<#5AE4B5>• <#40B7D6>/cosmetics - <#6D9DC5>Opens cosmetics GUI.\n" +
|
||||
"\n" +
|
||||
"<#5AE4B5>• <#40B7D6>/cosmetics dye <gray><BACKPACK/HAT></gray> - <#6D9DC5>Opens dye menu for specified cosmetic.\n" +
|
||||
"\n" +
|
||||
"<#5AE4B5>• <#40B7D6>/cosmetics help - <#6D9DC5>Opens this menu.\n" +
|
||||
"\n" +
|
||||
"\n" +
|
||||
"<st> </st>");
|
||||
}
|
||||
|
||||
@@ -5,5 +5,6 @@ public class Permission {
|
||||
public static final String DEFAULT_COMMAND = "hmccosmetics.cmd.default";
|
||||
public static final String DYE_COMMAND = "hmccosmetics.cmd.dye";
|
||||
public static final String RELOAD_COMMAND = "hmccosmetics.cmd.reload";
|
||||
public static final String HELP_COMMAND = "hmccosmetics.cmd.help";
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user