server.getPluginManager().registerEvents(this, DenizenAPI.getCurrentInstance());
// Get the CommandMap for the server
final Field commandMapField = server.getClass().getDeclaredField("commandMap");
commandMapField.setAccessible(true);
CommandMap commandMap = (CommandMap) commandMapField.get(server);
// Get the knownCommands for the server's CommandMap
final Field knownCommandsField = commandMap.getClass().getDeclaredField("knownCommands");
knownCommandsField.setAccessible(true);
knownCommands = (Map<String, Command>) knownCommandsField.get(commandMap);
// Get the HelpMap for the server
HelpMap helpMap = server.getHelpMap();