all repos — xrxs @ 940791631c398464e63264313f5872851d88b974

experimental networked application/game server with 9p

cart.h (raw)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
typedef struct UserInfo UserInfo;
typedef unsigned int uint;

typedef struct Cart {
  char name[32];
  char* rom;
  char* txt_data;
  char* sprite_data;
  char* audio_data;
} Cart;

Cart* create_cart(char* name);
Cart* find_cart(UserInfo* table, char* name);
int get_chunk(UserInfo* table, char* uname, char* chunk);
uint count_carts(UserInfo* table, char* name);
void destroy_cart(Cart* self);