Add CustomMobs plugin configuration and update command logic
Introduced a new configuration file for the CustomMobs plugin, specifying its details and commands. Updated the CommandManager to use "custommobs" instead of "fish" and added an alias "cm" for command execution.
This commit is contained in:
@@ -20,7 +20,7 @@ public class CommandManager implements CommandExecutor, TabExecutor {
|
||||
private final List<SubCommand> subCommands;
|
||||
|
||||
public CommandManager(Main main) {
|
||||
PluginCommand command = main.getCommand("fish");
|
||||
PluginCommand command = main.getCommand("custommobs");
|
||||
if (command == null) {
|
||||
subCommands = null;
|
||||
log.error("Unable to find transfer command.");
|
||||
@@ -28,6 +28,7 @@ public class CommandManager implements CommandExecutor, TabExecutor {
|
||||
}
|
||||
command.setExecutor(this);
|
||||
command.setTabCompleter(this);
|
||||
command.setAliases(List.of("cm"));
|
||||
|
||||
subCommands = Arrays.asList(
|
||||
new Spawn(main)
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
name: CustomMobs
|
||||
version: '1.0.0'
|
||||
main: com.alttd.event.Main
|
||||
description: A plugin to spawn custom mobs
|
||||
author: Stijn
|
||||
website: https://alttd.com
|
||||
api-version: '1.21'
|
||||
commands:
|
||||
event:
|
||||
description: Base command for 121 event
|
||||
permission: custommobs.use
|
||||
usage: /custommobs
|
||||
aliases:
|
||||
- cm
|
||||
Reference in New Issue
Block a user