eobish

view src/tileset.h @ 4:ce0548d24918

mostly works
author John Tsiombikas <nuclear@member.fsf.org>
date Sun, 18 Jan 2015 13:30:30 +0200
parents
children 0baf4e98315e
line source
1 #ifndef TILESET_H_
2 #define TILESET_H_
4 #include "image.h"
6 struct tile {
7 char *name;
8 struct image img;
9 int orig_x, orig_y;
10 };
12 struct tileset {
13 struct tile *tile;
14 int num_tiles;
16 struct color pal[256];
17 int pal_size;
18 };
20 int load_tileset(struct tileset *ts, const char *fname);
21 void destroy_tileset(struct tileset *ts);
23 struct tile *get_tile(struct tileset *ts, const char *name);
25 #endif /* TILESET_H_ */