about summary refs log tree commit diff homepage
path: root/torus.h
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2017-07-31 21:30:22 -0400
committerJune McEnroe <june@causal.agency>2017-07-31 21:30:22 -0400
commit87e515b927d15881e39b73e18ac211164f28b88f (patch)
tree10fa9a61bcc501fc0747771dcab996f964b78b57 /torus.h
parentPerform enter as two moves rather than a loop (diff)
downloadtorus-87e515b927d15881e39b73e18ac211164f28b88f.tar.gz
torus-87e515b927d15881e39b73e18ac211164f28b88f.zip
Show other clients' cursors
Also unfuck removing on send failure.
Diffstat (limited to '')
-rw-r--r--torus.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/torus.h b/torus.h
index ff9c0e8..9158ef7 100644
--- a/torus.h
+++ b/torus.h
@@ -47,6 +47,7 @@ enum ServerMessageType {
     SERVER_TILE,
     SERVER_MOVE,
     SERVER_PUT,
+    SERVER_CURSOR,
 };
 
 struct ServerMessage {
@@ -62,9 +63,17 @@ struct ServerMessage {
             uint8_t color;
             char cell;
         } p;
+        struct {
+            uint8_t oldCellX;
+            uint8_t oldCellY;
+            uint8_t newCellX;
+            uint8_t newCellY;
+        } c;
     } data;
 };
 
+#define CURSOR_NONE UINT8_MAX
+
 enum ClientMessageType {
     CLIENT_MOVE,
     CLIENT_PUT,