ToolSet / com.zndevs.toolset.tools / ToolSetCommandTools

ToolSetCommandTools

object ToolSetCommandTools

Tools to help with commands

Properties

commandExecutors val commandExecutors: MutableMap<String, ToolSetCommand>
commandPlugins val commandPlugins: MutableMap<String, JavaPlugin>
toolSetPlugins val toolSetPlugins: MutableMap<String, JavaPlugin>
toolSetPluginsInternal val toolSetPluginsInternal: MutableMap<String, JavaPlugin>

Functions

addPlugin fun addPlugin(pluginName: String, plugin: JavaPlugin): Unit
Adds a plugin to the list of currently running plugins
disableCommand fun disableCommand(command: String): Boolean
Disables a plugin’s command
disableCommandSoft fun disableCommandSoft(commandName: String): Unit
enableCommand fun enableCommand(plugin: JavaPlugin, command: String, executor: ToolSetCommand): Unit
getPlugin fun getPlugin(pluginName: String): JavaPlugin?
Gets a plugin from the list of currently running plugins
registerIfEnabled fun registerIfEnabled(commandPlugin: JavaPlugin?, command: String, executor: ToolSetCommand): Boolean
Register a plugin command if it is set to be enabled in its config
reloadCommands fun reloadCommands(): Unit
Reload commands from a pluginfun reloadCommands(setToAnythingToGetReturnValue: Any?): String
Reload commands from a plugin and send a message to the executor
unloadAllCommands fun unloadAllCommands(): Unit
Unloads all current commands