diff options
author | Torui <44932079+ToruiDev@users.noreply.github.com> | 2022-03-23 19:08:57 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-23 19:08:57 +0100 |
commit | bb935e5f731214377cbb55d7c00d3e7c0b49db4c (patch) | |
tree | 5b501812588da8439bd54ea3599c1a44cb856ce0 /src/main/java/de/torui/coflsky/EventRegistry.java | |
parent | 1caa3e1840e51800200458b776712f38b470d772 (diff) | |
parent | 22ac509f260f6979038ad6626dd222ce43a3532a (diff) | |
download | COFL-bb935e5f731214377cbb55d7c00d3e7c0b49db4c.tar.gz COFL-bb935e5f731214377cbb55d7c00d3e7c0b49db4c.tar.bz2 COFL-bb935e5f731214377cbb55d7c00d3e7c0b49db4c.zip |
Merge pull request #51 from Coflnet/feature/implicit-connect
implicit connect & bug fixes
Diffstat (limited to 'src/main/java/de/torui/coflsky/EventRegistry.java')
-rw-r--r-- | src/main/java/de/torui/coflsky/EventRegistry.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/main/java/de/torui/coflsky/EventRegistry.java b/src/main/java/de/torui/coflsky/EventRegistry.java index 511b155..4b5186b 100644 --- a/src/main/java/de/torui/coflsky/EventRegistry.java +++ b/src/main/java/de/torui/coflsky/EventRegistry.java @@ -56,18 +56,20 @@ public class EventRegistry { } if(CoflSky.keyBindings[1].isKeyDown()) { - if((System.currentTimeMillis() - LastClick) >= 500) { + if((System.currentTimeMillis() - LastClick) >= 400) { Flip f = WSCommandHandler.flipHandler.fds.GetHighestFlip(); if(f != null) { + WSCommandHandler.Execute("/viewauction " + f.id, null); LastClick = System.currentTimeMillis(); String command = WSClient.gson.toJson("/viewauction " + f.id); - WSCommandHandler.Execute("/viewauction " + f.id, null); WSCommandHandler.flipHandler.fds.InvalidateFlip(f); - WSCommandHandler.Execute("/cofl track besthotkey " + f.id, Minecraft.getMinecraft().thePlayer); + WSCommandHandler.Execute("/cofl track besthotkey " + f.id, Minecraft.getMinecraft().thePlayer); CoflSky.Wrapper.SendMessage(new JsonStringCommand(CommandType.Clicked, command)); + } else { + WSCommandHandler.Execute("/cofl dialog nobestflip", Minecraft.getMinecraft().thePlayer); } } |