diff options
author | bowser0000 <bowser0000@gmail.com> | 2020-11-21 19:16:08 -0500 |
---|---|---|
committer | bowser0000 <bowser0000@gmail.com> | 2020-11-21 19:16:08 -0500 |
commit | 43c6b9c0387eb0294d12f9de22baad7f9235b86f (patch) | |
tree | 8af2acaf7ed14d518984b83a56f8a617e2c4abdd /src/main/java/me/Danker/commands/DisplayCommand.java | |
parent | b8481811e5e25f2a710053444347295010a6155c (diff) | |
download | SkyblockMod-43c6b9c0387eb0294d12f9de22baad7f9235b86f.tar.gz SkyblockMod-43c6b9c0387eb0294d12f9de22baad7f9235b86f.tar.bz2 SkyblockMod-43c6b9c0387eb0294d12f9de22baad7f9235b86f.zip |
Access static methods in static ways and remove unused imports
Diffstat (limited to 'src/main/java/me/Danker/commands/DisplayCommand.java')
-rw-r--r-- | src/main/java/me/Danker/commands/DisplayCommand.java | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/main/java/me/Danker/commands/DisplayCommand.java b/src/main/java/me/Danker/commands/DisplayCommand.java index 6e00fba..2af402e 100644 --- a/src/main/java/me/Danker/commands/DisplayCommand.java +++ b/src/main/java/me/Danker/commands/DisplayCommand.java @@ -10,7 +10,6 @@ import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.BlockPos; import net.minecraft.util.ChatComponentText; -import net.minecraft.util.EnumChatFormatting; public class DisplayCommand extends CommandBase { public static String display; @@ -54,7 +53,6 @@ public class DisplayCommand extends CommandBase { return; } - final ConfigHandler cf = new ConfigHandler(); boolean showSession = false; if (arg1[arg1.length - 1].equalsIgnoreCase("session")) showSession = true; @@ -151,7 +149,7 @@ public class DisplayCommand extends CommandBase { } else if (arg1[0].equalsIgnoreCase("auto")) { auto = true; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display set to " + TheMod.SECONDARY_COLOUR + "auto" + TheMod.MAIN_COLOUR + ".")); - cf.writeBooleanConfig("misc", "autoDisplay", true); + ConfigHandler.writeBooleanConfig("misc", "autoDisplay", true); return; } else if (arg1[0].equalsIgnoreCase("off")) { display = "off"; @@ -161,8 +159,8 @@ public class DisplayCommand extends CommandBase { } auto = false; player.addChatMessage(new ChatComponentText(TheMod.MAIN_COLOUR + "Display set to " + TheMod.SECONDARY_COLOUR + display + TheMod.MAIN_COLOUR + ".")); - cf.writeBooleanConfig("misc", "autoDisplay", false); - cf.writeStringConfig("misc", "display", display); + ConfigHandler.writeBooleanConfig("misc", "autoDisplay", false); + ConfigHandler.writeStringConfig("misc", "display", display); } } |