Class CoreCommand
java.lang.Object
fr.luc.crcore.command.AbstractCommand
fr.luc.crcore.command.BaseCommand
fr.luc.crcore.command.builtin.CoreCommand
- All Implemented Interfaces:
Command, org.bukkit.command.CommandExecutor, org.bukkit.command.TabCompleter
Commande racine
/core. Container des groupes par défaut.
Branchée par CRCore.enable() sur la PluginCommand "core"
du plugin de jeu (qui doit l'avoir déclarée dans son plugin.yml).
Sans arguments, affiche l'aide des groupes disponibles. Avec team
<action>, route vers TeamGroupSubCommand.
Override
Pour remplacer un groupe entier :core.getCoreCommand().replaceSubCommand("team", new MyTeamGroup(svc));
Pour remplacer une feuille :
core.getCoreCommand().findSubCommand("team")
.ifPresent(t -> t.replaceSubCommand("create", new MyCreate(svc)));
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final PlayerProfileServiceprotected final TeamService -
Constructor Summary
ConstructorsConstructorDescriptionCoreCommand(TeamService teamService, PlayerProfileService playerProfileService) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidEnregistre les groupes par défaut.Methods inherited from class BaseCommand
handleResult, onCommand, onTabCompleteMethods inherited from class AbstractCommand
addAlias, addSubCommand, argument, buildContext, buildDefaultUsage, checkAccess, description, dispatch, execute, findSubCommand, getAliases, getDescription, getName, getPermission, getRequiredArgumentCount, getSubCommands, getTotalArgumentCount, getUsage, hasSubCommands, isPlayerOnly, listSubCommands, optionalArgument, permission, playerOnly, replaceSubCommand, tabComplete, usage
-
Field Details
-
teamService
-
playerProfileService
-
-
Constructor Details
-
CoreCommand
-
-
Method Details
-
registerDefaults
protected void registerDefaults()Enregistre les groupes par défaut. Override pour ajouter / retirer des groupes.
-