Use sorted containers for commands & aliases

This commit is contained in:
AnimeGitB 2022-07-21 21:17:53 +09:30 committed by Luke H-W
parent 104e04f70a
commit e9a95b89cf

View File

@ -8,9 +8,9 @@ import java.util.*;
@SuppressWarnings({"UnusedReturnValue", "unused"})
public final class CommandMap {
private final Map<String, CommandHandler> commands = new LinkedHashMap<>();
private final Map<String, CommandHandler> aliases = new LinkedHashMap<>();
private final Map<String, Command> annotations = new LinkedHashMap<>();
private final Map<String, CommandHandler> commands = new TreeMap<>();
private final Map<String, CommandHandler> aliases = new TreeMap<>();
private final Map<String, Command> annotations = new TreeMap<>();
private final Map<String, Integer> targetPlayerIds = new HashMap<>();
private static final String consoleId = "console";