Implement pack reading functions

This commit is contained in:
2023-11-02 00:12:03 +00:00
parent 7beac7e475
commit 041167d26f
2 changed files with 42 additions and 3 deletions

View File

@@ -6,7 +6,7 @@
typedef struct {
u64 size;
u8 *data;
u8 data[];
} buf_t;
typedef struct {
@@ -41,7 +41,8 @@ typedef struct asset_pack asset_pack_t;
bool create_asset_pack(const char *dirpath, const char *output);
asset_pack_t *load_asset_pack(const char *filepath);
// buf_t read_file_from_pack(pak_read_t *pack, const char *filename);
buf_t *read_file_from_pack(asset_pack_t *pack, const char *filename);
void close_pack_file(buf_t **buf);
void close_asset_pack(asset_pack_t **pack);
#endif // !PAK_H