diff options
author | TymanWasTaken <tyman@tyman.tech> | 2021-07-06 17:24:20 -0400 |
---|---|---|
committer | TymanWasTaken <tyman@tyman.tech> | 2021-07-06 17:24:20 -0400 |
commit | 98ee5a2ae8090c061b1e61e7955d793416991822 (patch) | |
tree | e34bb84ed247f08f2931f10d1dfbf6c8b883004c /src/main/java/com/thatgravyboat/skyblockhud/SkyblockHud.java | |
parent | c04ca523f9fb9f7adefa74587db61f76deeae9f0 (diff) | |
download | SkyblockHud-Death-Defied-98ee5a2ae8090c061b1e61e7955d793416991822.tar.gz SkyblockHud-Death-Defied-98ee5a2ae8090c061b1e61e7955d793416991822.tar.bz2 SkyblockHud-Death-Defied-98ee5a2ae8090c061b1e61e7955d793416991822.zip |
140?
Diffstat (limited to 'src/main/java/com/thatgravyboat/skyblockhud/SkyblockHud.java')
-rw-r--r-- | src/main/java/com/thatgravyboat/skyblockhud/SkyblockHud.java | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/src/main/java/com/thatgravyboat/skyblockhud/SkyblockHud.java b/src/main/java/com/thatgravyboat/skyblockhud/SkyblockHud.java index 8cd8baf..071d120 100644 --- a/src/main/java/com/thatgravyboat/skyblockhud/SkyblockHud.java +++ b/src/main/java/com/thatgravyboat/skyblockhud/SkyblockHud.java @@ -51,10 +51,7 @@ public class SkyblockHud { private File configFile; - private static final Set<String> SKYBLOCK_IN_ALL_LANGUAGES = Sets.newHashSet( - "SKYBLOCK", - "\u7A7A\u5C9B\u751F\u5B58" - ); + private static final Set<String> SKYBLOCK_IN_ALL_LANGUAGES = Sets.newHashSet("SKYBLOCK", "\u7A7A\u5C9B\u751F\u5B58"); private final Gson gson = new GsonBuilder().setPrettyPrinting().excludeFieldsWithoutExposeAnnotation().create(); @@ -90,9 +87,7 @@ public class SkyblockHud { if (configFile.exists()) { try ( - BufferedReader reader = new BufferedReader( - new InputStreamReader(new FileInputStream(configFile), StandardCharsets.UTF_8) - ) + BufferedReader reader = new BufferedReader(new InputStreamReader(new FileInputStream(configFile), StandardCharsets.UTF_8)) ) { config = gson.fromJson(reader, SBHConfig.class); } catch (Exception ignored) {} @@ -114,9 +109,7 @@ public class SkyblockHud { configFile.createNewFile(); try ( - BufferedWriter writer = new BufferedWriter( - new OutputStreamWriter(new FileOutputStream(configFile), StandardCharsets.UTF_8) - ) + BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(configFile), StandardCharsets.UTF_8)) ) { writer.write(gson.toJson(config)); } @@ -181,13 +174,7 @@ public class SkyblockHud { @SubscribeEvent(priority = EventPriority.HIGHEST) public void onStatusBar(ClientChatReceivedEvent event) { - if ( - Utils - .removeColor(event.message.getUnformattedText()) - .toLowerCase() - .trim() - .startsWith("your profile was changed to:") - ) { + if (Utils.removeColor(event.message.getUnformattedText()).toLowerCase().trim().startsWith("your profile was changed to:")) { MinecraftForge.EVENT_BUS.post(new ProfileSwitchedEvent()); } } |