From a2b5beb434b38aa8d0856166950053f8cf456f42 Mon Sep 17 00:00:00 2001 From: June McEnroe Date: Fri, 4 Jan 2019 13:22:21 -0500 Subject: Add teleportation "Spawns" in the old code. --- torus.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'torus.h') diff --git a/torus.h b/torus.h index 7da2915..b9d842f 100644 --- a/torus.h +++ b/torus.h @@ -104,6 +104,17 @@ static const size_t TilesSize = sizeof(struct Tile[TileRows][TileCols]); static const uint32_t TileInitX = 0; static const uint32_t TileInitY = 0; +static const struct { + uint32_t tileX; + uint32_t tileY; +} Ports[] = { + { TileInitX, TileInitY }, + { TileCols * 3 / 4, TileRows * 3 / 4 }, // NW + { TileCols * 1 / 4, TileRows * 3 / 4 }, // NE + { TileCols * 1 / 4, TileRows * 1 / 4 }, // SE + { TileCols * 3 / 4, TileRows * 1 / 4 }, // SW +}; + enum { MapRows = 11, MapCols = 11, @@ -152,6 +163,7 @@ struct ClientMessage { ClientFlip, ClientPut, ClientMap, + ClientTele, } type; union { struct { @@ -162,5 +174,6 @@ struct ClientMessage { uint8_t color; uint8_t cell; } put; + uint8_t port; }; }; -- cgit 1.4.1 1625d6db3'>tree commit diff
path: root/doc (unfollow)
Commit message (Expand)Author
2020-12-28Add mdoc lexerJune McEnroe
2020-12-28Lex strings inside macrosJune McEnroe
2020-12-28Set H_SETUNIQUEJune McEnroe
2020-12-28Add initial version of hilexJune McEnroe