diff options
Diffstat (limited to 'src/main/java/io/polyfrost/oneconfig/command/OneConfigCommand.java')
-rw-r--r-- | src/main/java/io/polyfrost/oneconfig/command/OneConfigCommand.java | 37 |
1 files changed, 8 insertions, 29 deletions
diff --git a/src/main/java/io/polyfrost/oneconfig/command/OneConfigCommand.java b/src/main/java/io/polyfrost/oneconfig/command/OneConfigCommand.java index df727a0..b210146 100644 --- a/src/main/java/io/polyfrost/oneconfig/command/OneConfigCommand.java +++ b/src/main/java/io/polyfrost/oneconfig/command/OneConfigCommand.java @@ -1,21 +1,16 @@ package io.polyfrost.oneconfig.command; -import io.polyfrost.oneconfig.gui.Window; import io.polyfrost.oneconfig.hud.gui.HudGui; -import io.polyfrost.oneconfig.themes.Themes; +import io.polyfrost.oneconfig.test.TestNanoVGGui; import io.polyfrost.oneconfig.utils.TickDelay; import net.minecraft.client.Minecraft; -import net.minecraft.command.ICommand; +import net.minecraft.command.CommandBase; import net.minecraft.command.ICommandSender; -import net.minecraft.util.BlockPos; -import net.minecraft.util.ChatComponentText; -import org.jetbrains.annotations.NotNull; -import java.io.File; import java.util.ArrayList; import java.util.List; -public class OneConfigCommand implements ICommand { +public class OneConfigCommand extends CommandBase { private static final Minecraft mc = Minecraft.getMinecraft(); @@ -39,37 +34,21 @@ public class OneConfigCommand implements ICommand { @Override public void processCommand(ICommandSender sender, String[] args) { - if (args.length == 0) new TickDelay(() -> mc.displayGuiScreen(new Window()), 1); + if (args.length == 0) ; //new TickDelay(() -> mc.displayGuiScreen(new Window()), 1); else { switch (args[0]) { case "hud": new TickDelay(() -> mc.displayGuiScreen(new HudGui()), 1); break; - case "theme": - mc.thePlayer.addChatMessage(new ChatComponentText("reloading theme!")); - Themes.openTheme(new File("OneConfig/themes/one.zip").getAbsoluteFile()); + case "lwjgl": + new TickDelay(() -> mc.displayGuiScreen(new TestNanoVGGui()), 1); break; } } } @Override - public boolean canCommandSenderUseCommand(ICommandSender sender) { - return true; - } - - @Override - public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) { - return null; - } - - @Override - public boolean isUsernameIndex(String[] args, int index) { - return false; - } - - @Override - public int compareTo(@NotNull ICommand o) { - return 0; + public int getRequiredPermissionLevel() { + return -1; } } |