1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-06-29 01:56:44 +02:00

Add networking to game engine / add multiplayer chess

This commit is contained in:
jfreegman
2021-01-17 13:29:13 -05:00
parent 60bdcf0ba5
commit 7aeb1a0aac
18 changed files with 1186 additions and 234 deletions

View File

@ -89,4 +89,15 @@ void game_util_move_coords(Direction direction, Coords *coords);
*/
int game_util_random_colour(void);
/*
* Packs an unsigned 32 bit integer `v` into `bytes`.
*/
size_t game_util_pack_u32(uint8_t *bytes, uint32_t v);
/*
* Unpacks an unsigned 32 bit integer in `bytes` to `v`.
*/
size_t game_util_unpack_u32(const uint8_t *bytes, uint32_t *v);
#endif // GAME_UTIL