Class SlimefunCommand

java.lang.Object
io.github.thebusybiscuit.slimefun4.core.commands.SlimefunCommand
All Implemented Interfaces:
org.bukkit.command.CommandExecutor, org.bukkit.event.Listener

public class SlimefunCommand extends Object implements org.bukkit.command.CommandExecutor, org.bukkit.event.Listener
This CommandExecutor holds the functionality of our /slimefun command.
Author:
TheBusyBiscuit
  • Constructor Details

    • SlimefunCommand

      public SlimefunCommand(@Nonnull Slimefun plugin)
      Creates a new instance of SlimefunCommand
      Parameters:
      plugin - The instance of our Slimefun
  • Method Details

    • register

      public void register()
    • getPlugin

      @Nonnull public Slimefun getPlugin()
    • getCommandUsage

      @Nonnull public Map<SubCommand,Integer> getCommandUsage()
      Returns a heatmap of how often certain commands are used.
      Returns:
      A Map holding the amount of times each command was run
    • onCommand

      public boolean onCommand(org.bukkit.command.CommandSender sender, org.bukkit.command.Command cmd, String label, String[] args)
      Specified by:
      onCommand in interface org.bukkit.command.CommandExecutor
    • sendHelp

      public void sendHelp(@Nonnull org.bukkit.command.CommandSender sender)
    • onCommand

      public void onCommand(org.bukkit.event.player.PlayerCommandPreprocessEvent e)
    • getSubCommandNames

      @Nonnull public List<String> getSubCommandNames()
      This returns A List containing every possible SubCommand of this Command.
      Returns:
      A List containing every SubCommand