diff options
author | XThe <101992755+SirXThe@users.noreply.github.com> | 2023-02-25 01:03:36 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-24 19:03:36 -0500 |
commit | 99fe13770d1460e07f465e0cb8e3967812fcef2f (patch) | |
tree | dd3eb73ca8629fd77e8e0c1c38d303ffc6d725b6 /src/main/kotlin | |
parent | 99be374aa343029e670dd1c8abcc834004363fc5 (diff) | |
download | Chatting-99fe13770d1460e07f465e0cb8e3967812fcef2f.tar.gz Chatting-99fe13770d1460e07f465e0cb8e3967812fcef2f.tar.bz2 Chatting-99fe13770d1460e07f465e0cb8e3967812fcef2f.zip |
fix: resolve messages get shuffled in whole chat screenshots (#19)
Diffstat (limited to 'src/main/kotlin')
-rw-r--r-- | src/main/kotlin/cc/woverflow/chatting/Chatting.kt | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/main/kotlin/cc/woverflow/chatting/Chatting.kt b/src/main/kotlin/cc/woverflow/chatting/Chatting.kt index 2faa234..ae5f8a1 100644 --- a/src/main/kotlin/cc/woverflow/chatting/Chatting.kt +++ b/src/main/kotlin/cc/woverflow/chatting/Chatting.kt @@ -2,9 +2,9 @@ package cc.woverflow.chatting import cc.polyfrost.oneconfig.libs.universal.UDesktop import cc.polyfrost.oneconfig.libs.universal.UResolution +import cc.polyfrost.oneconfig.utils.Notifications import cc.polyfrost.oneconfig.utils.commands.CommandManager import cc.polyfrost.oneconfig.utils.dsl.browseLink -import cc.polyfrost.oneconfig.utils.Notifications import cc.polyfrost.oneconfig.utils.gui.GuiUtils import cc.woverflow.chatting.chat.ChatSearchingManager import cc.woverflow.chatting.chat.ChatShortcuts @@ -41,6 +41,7 @@ import java.io.File import java.text.SimpleDateFormat import java.util.* import kotlin.collections.HashMap +import kotlin.collections.LinkedHashMap @Mod( @@ -116,7 +117,8 @@ object Chatting { if (isBetterChat) { Notifications.INSTANCE.send( NAME, - "BetterChat can be removed as it is replaced by Chatting. Click here to open your mods folder to delete the BetterChat file.", Runnable { + "BetterChat can be removed as it is replaced by Chatting. Click here to open your mods folder to delete the BetterChat file.", + Runnable { UDesktop.open(File("./mods")) }) } @@ -214,7 +216,7 @@ object Chatting { fun screenshotChat(scrollPos: Int) { val hud = Minecraft.getMinecraft().ingameGUI val chat = hud.chatGUI - val chatLines = HashMap<String, ChatLine>() + val chatLines = LinkedHashMap<String, ChatLine>() ChatSearchingManager.filterMessages( ChatSearchingManager.lastSearch, (chat as GuiNewChatAccessor).drawnChatLines |