diff --git a/src/main/java/net/cytonic/cytosis/commands/CommandHandler.java b/src/main/java/net/cytonic/cytosis/commands/CommandHandler.java index 8c42b9fd..f3b82273 100644 --- a/src/main/java/net/cytonic/cytosis/commands/CommandHandler.java +++ b/src/main/java/net/cytonic/cytosis/commands/CommandHandler.java @@ -2,6 +2,8 @@ import net.cytonic.cytosis.Cytosis; import net.minestom.server.command.CommandManager; +import net.minestom.server.entity.Player; + import java.util.Scanner; import java.util.concurrent.Executors; import java.util.concurrent.ScheduledExecutorService; @@ -20,7 +22,11 @@ public CommandHandler() { public void registerCystosisCommands() { CommandManager cm = Cytosis.getCommandManager(); cm.register(new GamemodeCommand()); - cm.register(new OperatorCommand()); + cm.register(new RankCommand()); + } + + public void recalculateCommands(Player player) { + player.sendPacket(Cytosis.getCommandManager().createDeclareCommandsPacket(player)); } public void setupConsole() {