mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-05-11 03:12:09 +00:00
Add MAXMUSNAMES constant
This commit is contained in:
parent
504788195e
commit
b089696021
3 changed files with 7 additions and 2 deletions
|
|
@ -50,6 +50,7 @@
|
||||||
// SRB2Kart
|
// SRB2Kart
|
||||||
#include "filesrch.h" // refreshdirmenu
|
#include "filesrch.h" // refreshdirmenu
|
||||||
#include "k_follower.h"
|
#include "k_follower.h"
|
||||||
|
#include "doomstat.h" // MAXMUSNAMES
|
||||||
|
|
||||||
// Loops through every constant and operation in word and performs its calculations, returning the final value.
|
// Loops through every constant and operation in word and performs its calculations, returning the final value.
|
||||||
fixed_t get_number(const char *word)
|
fixed_t get_number(const char *word)
|
||||||
|
|
@ -1173,7 +1174,8 @@ void readlevelheader(MYFILE *f, char * name)
|
||||||
do {
|
do {
|
||||||
deh_strlcpy(mapheaderinfo[num]->musname[j], tmp,
|
deh_strlcpy(mapheaderinfo[num]->musname[j], tmp,
|
||||||
sizeof(mapheaderinfo[num]->musname[j]), va("Level header %d: music", num));
|
sizeof(mapheaderinfo[num]->musname[j]), va("Level header %d: music", num));
|
||||||
j += 1;
|
if (j < MAXMUSNAMES)
|
||||||
|
j++;
|
||||||
} while ((tmp = strtok(NULL,",")) != NULL);
|
} while ((tmp = strtok(NULL,",")) != NULL);
|
||||||
mapheaderinfo[num]->musname_size = j;
|
mapheaderinfo[num]->musname_size = j;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -369,6 +369,8 @@ struct staffbrief_t
|
||||||
tic_t lap;
|
tic_t lap;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#define MAXMUSNAMES 3 // maximum definable music tracks per level
|
||||||
|
|
||||||
/** Map header information.
|
/** Map header information.
|
||||||
*/
|
*/
|
||||||
struct mapheader_t
|
struct mapheader_t
|
||||||
|
|
|
||||||
|
|
@ -100,6 +100,7 @@
|
||||||
#include "k_director.h" // K_InitDirector
|
#include "k_director.h" // K_InitDirector
|
||||||
#include "k_specialstage.h"
|
#include "k_specialstage.h"
|
||||||
#include "acs/interface.h"
|
#include "acs/interface.h"
|
||||||
|
#include "doomstat.h" // MAXMUSNAMES
|
||||||
|
|
||||||
// Replay names have time
|
// Replay names have time
|
||||||
#if !defined (UNDER_CE)
|
#if !defined (UNDER_CE)
|
||||||
|
|
@ -387,7 +388,7 @@ static void P_ClearSingleMapHeaderInfo(INT16 num)
|
||||||
mapheaderinfo[num]->typeoflevel = 0;
|
mapheaderinfo[num]->typeoflevel = 0;
|
||||||
mapheaderinfo[num]->gravity = DEFAULT_GRAVITY;
|
mapheaderinfo[num]->gravity = DEFAULT_GRAVITY;
|
||||||
mapheaderinfo[num]->keywords[0] = '\0';
|
mapheaderinfo[num]->keywords[0] = '\0';
|
||||||
for (i = 0; i < 3; i++)
|
for (i = 0; i < MAXMUSNAMES; i++)
|
||||||
{
|
{
|
||||||
sprintf(mapheaderinfo[num]->musname[i], "%.5sM", G_BuildMapName(num+1));
|
sprintf(mapheaderinfo[num]->musname[i], "%.5sM", G_BuildMapName(num+1));
|
||||||
mapheaderinfo[num]->musname[i][6] = 0;
|
mapheaderinfo[num]->musname[i][6] = 0;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue