aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/de/torui/coflsky/network
diff options
context:
space:
mode:
authorTorui <44932079+ToruiDev@users.noreply.github.com>2022-01-24 20:00:02 +0100
committerGitHub <noreply@github.com>2022-01-24 20:00:02 +0100
commit1caa3e1840e51800200458b776712f38b470d772 (patch)
tree1df9f67493c87ae24f19cb1f1c8ffa9503b4125b /src/main/java/de/torui/coflsky/network
parent4d2b8de15b223b2c9dfe389db36a593b1fabff0b (diff)
downloadCOFL-1caa3e1840e51800200458b776712f38b470d772.tar.gz
COFL-1caa3e1840e51800200458b776712f38b470d772.tar.bz2
COFL-1caa3e1840e51800200458b776712f38b470d772.zip
Feature/support new flips (#47)
* added rudimentary support for the new flips * Keypress * send "clicked" command * maybe fix the ConcurrentModificationException * add synchronized to relevant pieces of code * premature optimization * change timings to 50 seconds * switched to config file * workaround for #48 * change debounce mechanism * cofl track * fix #49 * fix command not getting data serialized * . * add id on claim * unset hotkey * Apply suggestions from code review remove tab from empty line Co-authored-by: Äkwav <16632490+Ekwav@users.noreply.github.com>
Diffstat (limited to 'src/main/java/de/torui/coflsky/network')
-rw-r--r--src/main/java/de/torui/coflsky/network/WSClient.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/de/torui/coflsky/network/WSClient.java b/src/main/java/de/torui/coflsky/network/WSClient.java
index 353fab0..ad9c436 100644
--- a/src/main/java/de/torui/coflsky/network/WSClient.java
+++ b/src/main/java/de/torui/coflsky/network/WSClient.java
@@ -122,15 +122,15 @@ public class WSClient extends WebSocketAdapter {
}
public void SendCommand(Command cmd) {
- Send(cmd);
+ SendCommand(new RawCommand(cmd.getType().ToJson(),gson.toJson(cmd.getData())));
}
-
public void SendCommand(RawCommand cmd) {
Send(cmd);
}
public void Send(Object obj) {
String json = gson.toJson(obj);
+ System.out.println("###Sending message of json value " + json);
this.socket.sendText(json);
}