Add properties registry. Start bounding defines with conditionals so users can change library allocation size.
This commit is contained in:
@@ -46,6 +46,7 @@ akerr_ErrorContext AKERR_NOIGNORE *akgl_game_init()
|
||||
CATCH(errctx, akgl_registry_init_character());
|
||||
CATCH(errctx, akgl_registry_init_font());
|
||||
CATCH(errctx, akgl_registry_init_music());
|
||||
CATCH(errctx, akgl_registry_init_properties());
|
||||
CATCH(errctx, akgl_registry_init_actor_state_strings());
|
||||
} CLEANUP {
|
||||
} PROCESS(errctx) {
|
||||
|
||||
@@ -13,6 +13,7 @@ SDL_PropertiesID AKGL_AKGL_REGISTRY_SPRITESHEET;
|
||||
SDL_PropertiesID AKGL_REGISTRY_CHARACTER;
|
||||
SDL_PropertiesID AKGL_REGISTRY_MUSIC;
|
||||
SDL_PropertiesID AKGL_REGISTRY_FONT;
|
||||
SDL_PropertiesID AKGL_REGISTRY_PROPERTIES;
|
||||
|
||||
akerr_ErrorContext *akgl_registry_init()
|
||||
{
|
||||
@@ -55,6 +56,14 @@ akerr_ErrorContext *akgl_registry_init_music()
|
||||
SUCCEED_RETURN(errctx);
|
||||
}
|
||||
|
||||
akerr_ErrorContext *akgl_registry_init_properties()
|
||||
{
|
||||
PREPARE_ERROR(errctx);
|
||||
AKGL_REGISTRY_PROPERTIES = SDL_CreateProperties();
|
||||
FAIL_ZERO_RETURN(errctx, AKGL_REGISTRY_PROPERTIES, AKERR_NULLPOINTER, "Error initializing properties registry");
|
||||
SUCCEED_RETURN(errctx);
|
||||
}
|
||||
|
||||
akerr_ErrorContext *akgl_registry_init_actor_state_strings()
|
||||
{
|
||||
int i = 0;
|
||||
|
||||
Reference in New Issue
Block a user