mirror of
https://gitlab.com/dosowisko.net/libsuperderpy.git
synced 2024-12-05 00:38:00 +01:00
gamestate: Add GetGamestateName function
This commit is contained in:
parent
1d569e9913
commit
7131334d6a
2 changed files with 5 additions and 0 deletions
|
@ -254,6 +254,10 @@ SYMBOL_EXPORT ALLEGRO_BITMAP* GetGamestateFramebuffer(struct Game* game, struct
|
|||
return gamestate->fb;
|
||||
}
|
||||
|
||||
SYMBOL_EXPORT char* GetGamestateName(struct Game* game, struct Gamestate* gamestate) {
|
||||
return AddGarbage(game, strdup(gamestate->name));
|
||||
}
|
||||
|
||||
SYMBOL_EXPORT struct Gamestate* GetNextGamestate(struct Game* game, struct Gamestate* gamestate) {
|
||||
if (!gamestate) {
|
||||
return game->_priv.gamestates;
|
||||
|
|
|
@ -67,6 +67,7 @@ void UnloadCurrentGamestate(struct Game* game);
|
|||
struct Gamestate* GetCurrentGamestate(struct Game* game);
|
||||
struct Gamestate* GetGamestate(struct Game* game, const char* name);
|
||||
ALLEGRO_BITMAP* GetGamestateFramebuffer(struct Game* game, struct Gamestate* gamestate);
|
||||
char* GetGamestateName(struct Game* game, struct Gamestate* gamestate);
|
||||
struct Gamestate* GetNextGamestate(struct Game* game, struct Gamestate* gamestate);
|
||||
bool IsGamestateVisible(struct Game* game, struct Gamestate* gamestate);
|
||||
|
||||
|
|
Loading…
Reference in a new issue