Merge pull request #21 from jvyden420/alphabetical

Quality of Life: Sort Modules/Commands alphabetically
This commit is contained in:
noil 2019-12-11 11:10:59 -05:00 committed by GitHub
commit ef31fe9fa4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 1 deletions

View File

@ -12,6 +12,8 @@ import net.minecraft.util.text.TextComponentString;
import java.io.File;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
/**
@ -70,6 +72,8 @@ public final class CommandManager {
//load our external commands
loadExternalCommands();
Collections.sort(commandList, Comparator.comparing(Command::getDisplayName));
}
/**

View File

@ -18,11 +18,12 @@ import me.rigamortis.seppuku.impl.module.player.*;
import me.rigamortis.seppuku.impl.module.render.*;
import me.rigamortis.seppuku.impl.module.ui.HudEditorModule;
import me.rigamortis.seppuku.impl.module.world.*;
import net.minecraft.client.Minecraft;
import java.io.File;
import java.lang.reflect.Field;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
/**
@ -154,6 +155,8 @@ public final class ModuleManager {
for (final Module module : moduleList)
Seppuku.INSTANCE.getEventManager().dispatchEvent(new EventModulePostLoaded(module));
Collections.sort(moduleList, Comparator.comparing(Module::getDisplayName));
}
/**