Subversion Repositories eduke32

Compare Revisions

Ignore whitespace Rev 5032 → Rev 5033

/polymer/eduke32/source/gamedef.c
98,6 → 98,7
{ CON_SETMUSICPOSITION, 20150116 },
{ CON_UNDEFINELEVEL, 20150208 },
{ CON_IFCUTSCENE, 20150210 },
{ CON_DEFINEVOLUMEFLAGS, 20150222 },
};
#endif
 
559,6 → 560,7
"undefinelevel", // 377
"startcutscene", // 378
"ifcutscene", // 379
"definevolumeflags", // 380
"<null>"
};
#endif
2228,6 → 2230,13
}
#endif
 
void C_DefineVolumeFlags(int32_t vol, int32_t flags)
{
Bassert((unsigned)vol < MAXVOLUMES);
 
EpisodeFlags[vol] = flags;
}
 
void C_UndefineVolume(int32_t vol)
{
Bassert((unsigned)vol < MAXVOLUMES);
5416,6 → 5425,26
EpisodeNames[j][i] = '\0';
continue;
 
case CON_DEFINEVOLUMEFLAGS:
g_scriptPtr--;
C_GetNextValue(LABEL_DEFINE);
g_scriptPtr--;
j = *g_scriptPtr;
C_GetNextValue(LABEL_DEFINE);
g_scriptPtr--;
k = *g_scriptPtr;
 
if (EDUKE32_PREDICT_FALSE((unsigned)j > MAXVOLUMES-1))
{
initprintf("%s:%d: error: volume number exceeds maximum volume count.\n",g_szScriptFileName,g_lineNumber);
g_numCompilerErrors++;
C_NextLine();
continue;
}
 
C_DefineVolumeFlags(j, k);
continue;
 
case CON_DEFINEGAMEFUNCNAME:
g_scriptPtr--;
C_GetNextValue(LABEL_DEFINE);