From 82a8c9b7f800f4fdcbb20e86ae125cda4dd6631d Mon Sep 17 00:00:00 2001 From: bowser0000 Date: Sat, 25 Jul 2020 22:53:37 -0400 Subject: Make T6/T4 enchants golden --- me/Danker/commands/ToggleCommand.java | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'me/Danker/commands/ToggleCommand.java') diff --git a/me/Danker/commands/ToggleCommand.java b/me/Danker/commands/ToggleCommand.java index 6baa7af..0e893c4 100644 --- a/me/Danker/commands/ToggleCommand.java +++ b/me/Danker/commands/ToggleCommand.java @@ -12,6 +12,7 @@ import net.minecraft.util.EnumChatFormatting; public class ToggleCommand extends CommandBase implements ICommand { public static boolean gpartyToggled; public static boolean coordsToggled; + public static boolean goldenToggled; @Override public String getCommandName() { @@ -20,7 +21,7 @@ public class ToggleCommand extends CommandBase implements ICommand { @Override public String getCommandUsage(ICommandSender arg0) { - return getCommandName() + " "; + return getCommandName() + " "; } @Override @@ -34,7 +35,7 @@ public class ToggleCommand extends CommandBase implements ICommand { final ConfigHandler cf = new ConfigHandler(); if (arg1.length == 0) { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle ")); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle ")); return; } @@ -46,11 +47,16 @@ public class ToggleCommand extends CommandBase implements ICommand { coordsToggled = !coordsToggled; cf.writeBooleanConfig("toggles", "Coords", coordsToggled); player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "Coord/Angle display has been set to " + EnumChatFormatting.DARK_GREEN + coordsToggled + EnumChatFormatting.GREEN + ".")); + } else if (arg1[0].equalsIgnoreCase("golden")) { + goldenToggled = !goldenToggled; + cf.writeBooleanConfig("toggles", "Golden", goldenToggled); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "Golden T6 enchants has been set to " + EnumChatFormatting.DARK_GREEN + goldenToggled + EnumChatFormatting.GREEN + ".")); } else if (arg1[0].equalsIgnoreCase("list")) { player.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "Guild party notifications: " + EnumChatFormatting.DARK_GREEN + gpartyToggled + "\n" + - EnumChatFormatting.GREEN + " Coord/Angle display: " + EnumChatFormatting.DARK_GREEN + coordsToggled)); + EnumChatFormatting.GREEN + " Coord/Angle display: " + EnumChatFormatting.DARK_GREEN + coordsToggled + "\n" + + EnumChatFormatting.GREEN + " Golden T6 enchants: " + EnumChatFormatting.DARK_GREEN + goldenToggled)); } else { - player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle ")); + player.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "Usage: /toggle ")); } } } -- cgit