diff options
author | Lorenz <ESs95s3P5z8Pheb> | 2022-07-12 14:31:42 +0200 |
---|---|---|
committer | Lorenz <ESs95s3P5z8Pheb> | 2022-07-12 14:31:42 +0200 |
commit | 44744bc03b6cfca96a94e6a46e744d9db64f9206 (patch) | |
tree | a91466feae497ecdbce0533c573b8fbc8d15a0be | |
parent | a86b0aec776b3482ea6dc2e34ef3a6b49dcaaa06 (diff) | |
parent | 1a279442f2f9a4a98bbbf2e05b741c337703eefc (diff) | |
download | skyhanni-44744bc03b6cfca96a94e6a46e744d9db64f9206.tar.gz skyhanni-44744bc03b6cfca96a94e6a46e744d9db64f9206.tar.bz2 skyhanni-44744bc03b6cfca96a94e6a46e744d9db64f9206.zip |
Merge remote-tracking branch 'origin/master'
-rw-r--r-- | src/main/java/at/lorenz/mod/LorenzMod.java | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/src/main/java/at/lorenz/mod/LorenzMod.java b/src/main/java/at/lorenz/mod/LorenzMod.java index 499813472..1c5dac597 100644 --- a/src/main/java/at/lorenz/mod/LorenzMod.java +++ b/src/main/java/at/lorenz/mod/LorenzMod.java @@ -16,6 +16,8 @@ import at.lorenz.mod.test.LorenzTest; import com.google.gson.Gson; import com.google.gson.GsonBuilder; import com.thatgravyboat.skyblockhud_2.commands.Commands; +import java.io.*; +import java.nio.charset.StandardCharsets; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiScreen; import net.minecraftforge.common.MinecraftForge; @@ -25,9 +27,6 @@ import net.minecraftforge.fml.common.event.FMLPreInitializationEvent; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import net.minecraftforge.fml.common.gameevent.TickEvent; -import java.io.*; -import java.nio.charset.StandardCharsets; - @Mod(modid = LorenzMod.MODID, version = LorenzMod.VERSION) public class LorenzMod { @@ -106,16 +105,14 @@ public class LorenzMod { try { //noinspection ResultOfMethodCallIgnored configDirectory.mkdir(); - } catch (Exception ignored) { - } + } catch (Exception ignored) {} configFile = new File(configDirectory, "config.json"); if (configFile.exists()) { try (BufferedReader reader = new BufferedReader(new InputStreamReader(new FileInputStream(configFile), StandardCharsets.UTF_8))) { feature = gson.fromJson(reader, Features.class); - } catch (Exception ignored) { - } + } catch (Exception ignored) {} } if (feature == null) { @@ -133,8 +130,7 @@ public class LorenzMod { try (BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(configFile), StandardCharsets.UTF_8))) { writer.write(gson.toJson(feature)); } - } catch (IOException ignored) { - } + } catch (IOException ignored) {} } // @EventHandler |