Call it KEYWORDS

This commit is contained in:
James R 2020-01-08 14:41:38 -08:00
parent 74364b84f9
commit 735289502c
5 changed files with 8 additions and 8 deletions

View file

@ -1629,10 +1629,10 @@ static void readlevelheader(MYFILE *f, INT32 num)
mapheaderinfo[num-1]->typeoflevel = tol; mapheaderinfo[num-1]->typeoflevel = tol;
} }
} }
else if (fastcmp(word, "KEYWORD")) else if (fastcmp(word, "KEYWORDS"))
{ {
deh_strlcpy(mapheaderinfo[num-1]->keyword, word2, deh_strlcpy(mapheaderinfo[num-1]->keywords, word2,
sizeof(mapheaderinfo[num-1]->keyword), va("Level header %d: keyword", num)); sizeof(mapheaderinfo[num-1]->keywords), va("Level header %d: keywords", num));
} }
else if (fastcmp(word, "MUSIC")) else if (fastcmp(word, "MUSIC"))
{ {

View file

@ -289,7 +289,7 @@ typedef struct
UINT8 actnum; ///< Act number or 0 for none. UINT8 actnum; ///< Act number or 0 for none.
UINT32 typeoflevel; ///< Combination of typeoflevel flags. UINT32 typeoflevel; ///< Combination of typeoflevel flags.
INT16 nextlevel; ///< Map number of next level, or 1100-1102 to end. INT16 nextlevel; ///< Map number of next level, or 1100-1102 to end.
char keyword[33]; ///< Keywords separated by space to search for. 32 characters. char keywords[33]; ///< Keywords separated by space to search for. 32 characters.
char musname[7]; ///< Music track to play. "" for no music. char musname[7]; ///< Music track to play. "" for no music.
UINT16 mustrack; ///< Subsong to play. Only really relevant for music modules and specific formats supported by GME. 0 to ignore. UINT16 mustrack; ///< Subsong to play. Only really relevant for music modules and specific formats supported by GME. 0 to ignore.
UINT32 muspos; ///< Music position to jump to. UINT32 muspos; ///< Music position to jump to.

View file

@ -4763,7 +4763,7 @@ INT32 G_FindMap(const char *mapname, char **foundmapnamep,
realmapname, mapname, wanttable); realmapname, mapname, wanttable);
measurekeywords(&freq[freqc], measurekeywords(&freq[freqc],
&freq[freqc].keywhd, &freq[freqc].keywhc, &freq[freqc].keywhd, &freq[freqc].keywhc,
mapheaderinfo[i]->keyword, mapname, wanttable); mapheaderinfo[i]->keywords, mapname, wanttable);
if (freq[freqc].total) if (freq[freqc].total)
freqc++; freqc++;
} }

View file

@ -2014,8 +2014,8 @@ static int mapheaderinfo_get(lua_State *L)
lua_pushinteger(L, header->typeoflevel); lua_pushinteger(L, header->typeoflevel);
else if (fastcmp(field,"nextlevel")) else if (fastcmp(field,"nextlevel"))
lua_pushinteger(L, header->nextlevel); lua_pushinteger(L, header->nextlevel);
else if (fastcmp(field,"keyword")) else if (fastcmp(field,"keywords"))
lua_pushstring(L, header->keyword); lua_pushstring(L, header->keywords);
else if (fastcmp(field,"musname")) else if (fastcmp(field,"musname"))
lua_pushstring(L, header->musname); lua_pushstring(L, header->musname);
else if (fastcmp(field,"mustrack")) else if (fastcmp(field,"mustrack"))

View file

@ -222,7 +222,7 @@ static void P_ClearSingleMapHeaderInfo(INT16 i)
mapheaderinfo[num]->typeoflevel = 0; mapheaderinfo[num]->typeoflevel = 0;
mapheaderinfo[num]->nextlevel = (INT16)(i + 1); mapheaderinfo[num]->nextlevel = (INT16)(i + 1);
mapheaderinfo[num]->startrings = 0; mapheaderinfo[num]->startrings = 0;
mapheaderinfo[num]->keyword[0] = '\0'; mapheaderinfo[num]->keywords[0] = '\0';
snprintf(mapheaderinfo[num]->musname, 7, "%sM", G_BuildMapName(i)); snprintf(mapheaderinfo[num]->musname, 7, "%sM", G_BuildMapName(i));
mapheaderinfo[num]->musname[6] = 0; mapheaderinfo[num]->musname[6] = 0;
mapheaderinfo[num]->mustrack = 0; mapheaderinfo[num]->mustrack = 0;