diff options
author | June McEnroe <june@causal.agency> | 2017-08-28 23:38:40 -0400 |
---|---|---|
committer | June McEnroe <june@causal.agency> | 2017-08-28 23:38:40 -0400 |
commit | ce13621292bdfeafd7c6561c432a1d96deccbd3a (patch) | |
tree | f2cc5b128e0954be89a0568e7b5c30b3486d1fac /client.c | |
parent | Move license above includes (diff) | |
download | torus-ce13621292bdfeafd7c6561c432a1d96deccbd3a.tar.gz torus-ce13621292bdfeafd7c6561c432a1d96deccbd3a.zip |
Add respawning
Diffstat (limited to '')
-rw-r--r-- | client.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/client.c b/client.c index f6fc9a9..f477602 100644 --- a/client.c +++ b/client.c @@ -65,6 +65,11 @@ static void clientPut(uint8_t color, char cell) { clientMessage(&msg); } +static void clientSpawn(void) { + struct ClientMessage msg = { .type = CLIENT_SPAWN }; + clientMessage(&msg); +} + static uint8_t inputColor = COLOR_WHITE; static void colorFg(uint8_t fg) { @@ -180,6 +185,7 @@ static void readInput(void) { case ESC: mode = MODE_NORMAL; break; case 'q': endwin(); exit(EX_OK); + case 'Q': clientSpawn(); break; case 'a': clientMove(1, 0); // fallthrough case 'i': insertMode(1, 0); break; |