mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-29 07:22:07 +00:00
- exported gamestate variable and forced it to 32 bit internally.
- forced gameaction_t to 32 bit to avoid problems with undefined size issues.
This commit is contained in:
parent
65c4653f59
commit
fc101049c6
4 changed files with 20 additions and 5 deletions
|
@ -55,7 +55,7 @@ struct event_t
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
typedef enum
|
enum gameaction_t : int
|
||||||
{
|
{
|
||||||
ga_nothing,
|
ga_nothing,
|
||||||
ga_loadlevel,
|
ga_loadlevel,
|
||||||
|
@ -75,7 +75,7 @@ typedef enum
|
||||||
ga_screenshot,
|
ga_screenshot,
|
||||||
ga_togglemap,
|
ga_togglemap,
|
||||||
ga_fullconsole,
|
ga_fullconsole,
|
||||||
} gameaction_t;
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -64,7 +64,7 @@ typedef enum
|
||||||
// The current state of the game: whether we are
|
// The current state of the game: whether we are
|
||||||
// playing, gazing at the intermission screen,
|
// playing, gazing at the intermission screen,
|
||||||
// the game final animation, or a demo.
|
// the game final animation, or a demo.
|
||||||
typedef enum
|
enum gamestate_t : int
|
||||||
{
|
{
|
||||||
GS_LEVEL,
|
GS_LEVEL,
|
||||||
GS_INTERMISSION,
|
GS_INTERMISSION,
|
||||||
|
@ -79,7 +79,7 @@ typedef enum
|
||||||
GS_FORCEWIPEFADE = -2,
|
GS_FORCEWIPEFADE = -2,
|
||||||
GS_FORCEWIPEBURN = -3,
|
GS_FORCEWIPEBURN = -3,
|
||||||
GS_FORCEWIPEMELT = -4
|
GS_FORCEWIPEMELT = -4
|
||||||
} gamestate_t;
|
};
|
||||||
|
|
||||||
extern gamestate_t gamestate;
|
extern gamestate_t gamestate;
|
||||||
|
|
||||||
|
|
|
@ -851,7 +851,10 @@ void InitThingdef()
|
||||||
fieldptr = new PField("playeringame", parray, VARF_Native | VARF_Static | VARF_ReadOnly, (intptr_t)&playeringame);
|
fieldptr = new PField("playeringame", parray, VARF_Native | VARF_Static | VARF_ReadOnly, (intptr_t)&playeringame);
|
||||||
Namespaces.GlobalNamespace->Symbols.AddSymbol(fieldptr);
|
Namespaces.GlobalNamespace->Symbols.AddSymbol(fieldptr);
|
||||||
|
|
||||||
fieldptr = new PField("gameaction", TypeUInt8, VARF_Native | VARF_Static, (intptr_t)&gameaction);
|
fieldptr = new PField("gameaction", TypeUInt32, VARF_Native | VARF_Static, (intptr_t)&gameaction);
|
||||||
|
Namespaces.GlobalNamespace->Symbols.AddSymbol(fieldptr);
|
||||||
|
|
||||||
|
fieldptr = new PField("gamestate", TypeSInt32, VARF_Native | VARF_Static | VARF_ReadOnly, (intptr_t)&gamestate);
|
||||||
Namespaces.GlobalNamespace->Symbols.AddSymbol(fieldptr);
|
Namespaces.GlobalNamespace->Symbols.AddSymbol(fieldptr);
|
||||||
|
|
||||||
fieldptr = new PField("skyflatnum", TypeTextureID, VARF_Native | VARF_Static | VARF_ReadOnly, (intptr_t)&skyflatnum);
|
fieldptr = new PField("skyflatnum", TypeTextureID, VARF_Native | VARF_Static | VARF_ReadOnly, (intptr_t)&skyflatnum);
|
||||||
|
|
|
@ -1029,6 +1029,18 @@ enum PaletteFlashFlags
|
||||||
PF_HAZARD = 8,
|
PF_HAZARD = 8,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
enum EGameState
|
||||||
|
{
|
||||||
|
GS_LEVEL,
|
||||||
|
GS_INTERMISSION,
|
||||||
|
GS_FINALE,
|
||||||
|
GS_DEMOSCREEN,
|
||||||
|
GS_FULLCONSOLE,
|
||||||
|
GS_HIDECONSOLE,
|
||||||
|
GS_STARTUP,
|
||||||
|
GS_TITLELEVEL,
|
||||||
|
}
|
||||||
|
|
||||||
enum EGameAction
|
enum EGameAction
|
||||||
{
|
{
|
||||||
ga_nothing,
|
ga_nothing,
|
||||||
|
|
Loading…
Reference in a new issue