mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-24 07:50:59 +00:00
Support saving specified CON arrays in map states
git-svn-id: https://svn.eduke32.com/eduke32@5860 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
e2fd26ca2e
commit
559a34e875
1 changed files with 16 additions and 1 deletions
|
@ -3015,6 +3015,7 @@ DO_DEFSTATE:
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
case CON_GAMEARRAY:
|
case CON_GAMEARRAY:
|
||||||
|
{
|
||||||
if (EDUKE32_PREDICT_FALSE(isdigit(*textptr) || (*textptr == '-')))
|
if (EDUKE32_PREDICT_FALSE(isdigit(*textptr) || (*textptr == '-')))
|
||||||
{
|
{
|
||||||
C_GetNextLabelName();
|
C_GetNextLabelName();
|
||||||
|
@ -3042,10 +3043,22 @@ DO_DEFSTATE:
|
||||||
}
|
}
|
||||||
|
|
||||||
C_GetNextValue(LABEL_DEFINE);
|
C_GetNextValue(LABEL_DEFINE);
|
||||||
Gv_NewArray(label+(g_labelCnt<<6),NULL,*(g_scriptPtr-1), GAMEARRAY_NORMAL);
|
|
||||||
|
char const * const arrayName = label+(g_labelCnt<<6);
|
||||||
|
int arrayFlags = GAMEARRAY_NORMAL;
|
||||||
|
|
||||||
|
if (C_GetKeyword() == -1)
|
||||||
|
{
|
||||||
|
C_GetNextValue(LABEL_DEFINE);
|
||||||
|
arrayFlags = GAMEARRAY_NORMAL | *(g_scriptPtr-1);
|
||||||
|
g_scriptPtr--;
|
||||||
|
}
|
||||||
|
|
||||||
|
Gv_NewArray(arrayName, NULL, *(g_scriptPtr-1), arrayFlags);
|
||||||
|
|
||||||
g_scriptPtr -= 2; // no need to save in script...
|
g_scriptPtr -= 2; // no need to save in script...
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
case CON_DEFINE:
|
case CON_DEFINE:
|
||||||
{
|
{
|
||||||
|
@ -6178,6 +6191,8 @@ static void C_AddDefaultDefinitions(void)
|
||||||
C_AddDefinition("PROJ_WORKSLIKE",PROJ_WORKSLIKE,LABEL_DEFINE);
|
C_AddDefinition("PROJ_WORKSLIKE",PROJ_WORKSLIKE,LABEL_DEFINE);
|
||||||
C_AddDefinition("PROJ_XREPEAT",PROJ_XREPEAT,LABEL_DEFINE);
|
C_AddDefinition("PROJ_XREPEAT",PROJ_XREPEAT,LABEL_DEFINE);
|
||||||
C_AddDefinition("PROJ_YREPEAT",PROJ_YREPEAT,LABEL_DEFINE);
|
C_AddDefinition("PROJ_YREPEAT",PROJ_YREPEAT,LABEL_DEFINE);
|
||||||
|
|
||||||
|
C_AddDefinition("GAMEARRAY_RESTORE", GAMEARRAY_RESTORE, LABEL_DEFINE);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue