eco2d/code/game/header/assets.h

29 lines
490 B
C
Raw Normal View History

2021-01-18 14:46:11 +00:00
#pragma once
#include "system.h"
2021-05-12 17:26:41 +00:00
#define ASSET_INVALID 0xFF
2021-01-18 14:46:11 +00:00
2021-05-12 17:26:41 +00:00
typedef enum {
2021-01-18 14:46:11 +00:00
ASSET_PLAYER,
2021-05-12 17:26:41 +00:00
ASSET_THING,
MAX_ASSETS,
FORCE_ASSET_UINT16 = UINT16_MAX
} asset_id;
typedef enum {
AKIND_TEXTURE,
AKIND_SOUND,
FORCE_AKIND_UINT8 = UINT8_MAX
} asset_kind;
int32_t assets_setup(void);
void assets_destroy(void);
uint16_t assets_find(asset_id id);
2021-01-18 14:46:11 +00:00
2021-05-12 17:26:41 +00:00
asset_kind assets_get_kind(uint16_t id);
void *assets_get_snd(uint16_t id);
void *assets_get_tex(uint16_t id);