diff options
author | syeyoung <cyong06@naver.com> | 2021-05-23 17:38:57 +0900 |
---|---|---|
committer | syeyoung <cyong06@naver.com> | 2021-05-23 17:38:57 +0900 |
commit | bd37606a7fd3f46606b0eded6faa48131ae0a406 (patch) | |
tree | 2a67ad842f821c817806c3f6583a746c8c40ad6e /src/main/java/kr/syeyoung/dungeonsguide | |
parent | 08fea7fdbea175ca09ccde72ef62ee7e36026fe0 (diff) | |
download | Skyblock-Dungeons-Guide-bd37606a7fd3f46606b0eded6faa48131ae0a406.tar.gz Skyblock-Dungeons-Guide-bd37606a7fd3f46606b0eded6faa48131ae0a406.tar.bz2 Skyblock-Dungeons-Guide-bd37606a7fd3f46606b0eded6faa48131ae0a406.zip |
Add first-time-installing-dungeonsguide-message
Diffstat (limited to 'src/main/java/kr/syeyoung/dungeonsguide')
-rwxr-xr-x | src/main/java/kr/syeyoung/dungeonsguide/DungeonsGuide.java | 6 | ||||
-rwxr-xr-x | src/main/java/kr/syeyoung/dungeonsguide/eventlistener/DungeonListener.java | 10 |
2 files changed, 13 insertions, 3 deletions
diff --git a/src/main/java/kr/syeyoung/dungeonsguide/DungeonsGuide.java b/src/main/java/kr/syeyoung/dungeonsguide/DungeonsGuide.java index 63ba70a9..a169eeda 100755 --- a/src/main/java/kr/syeyoung/dungeonsguide/DungeonsGuide.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/DungeonsGuide.java @@ -159,11 +159,14 @@ public class DungeonsGuide implements DGInterface, CloseListener { ProgressManager.pop(progressbar); } + @Getter + private boolean firstTimeUsingDG = false; public void pre(FMLPreInitializationEvent event) { configDir = new File(event.getModConfigurationDirectory(),"dungeonsguide"); File configFile = new File(configDir, "config.json"); if (!configFile.exists()) { configDir.mkdirs(); + firstTimeUsingDG = true; } Config.f = configFile; Minecraft.getMinecraft().getFramebuffer().enableStencil(); @@ -183,9 +186,6 @@ public class DungeonsGuide implements DGInterface, CloseListener { inputStream.close(); } - private void combineConfig(Configuration saved, Configuration newest) { - } - @Getter private File configDir; diff --git a/src/main/java/kr/syeyoung/dungeonsguide/eventlistener/DungeonListener.java b/src/main/java/kr/syeyoung/dungeonsguide/eventlistener/DungeonListener.java index 334f9997..19daebc5 100755 --- a/src/main/java/kr/syeyoung/dungeonsguide/eventlistener/DungeonListener.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/eventlistener/DungeonListener.java @@ -229,6 +229,16 @@ public class DungeonListener { } } + + @SubscribeEvent + public void onHypixelJoin(HypixelJoinedEvent skyblockJoinedEvent) { + if (DungeonsGuide.getDungeonsGuide().isFirstTimeUsingDG()) { + Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §fThank you for installing DungeonsGuide, the most intelligent skyblock dungeon mod!")); + Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §fThe gui for relocating GUI Elements and enabling or disabling features can be opened by typing §e/dg")); + Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText("§eDungeons Guide §7:: §fType §e/dg help §fto view full list of commands offered by dungeons guide!")); + } + } + @SubscribeEvent public void onRender(RenderGameOverlayEvent.Post postRender) { try { |