Dehardcode "titlemusicstart" (position in O__TITLE the titlescreen starts on)

This commit is contained in:
toaster 2024-03-23 17:34:47 +00:00 committed by James R
parent a4f2712d8a
commit 93b08c8512
3 changed files with 8 additions and 1 deletions

View file

@ -3659,6 +3659,11 @@ void readmaincfg(MYFILE *f, boolean mainfile)
titlescrollyspeed = get_number(word2);
titlechanged = true;
}
else if (fastcmp(word, "TITLESMUSICSTART"))
{
titlemusicstart = (UINT32)get_number(word2);
titlechanged = true;
}
else if (fastcmp(word, "NUMDEMOS"))
{
numDemos = (UINT8)get_number(word2);

View file

@ -56,6 +56,7 @@
INT32 finalecount;
INT32 titlescrollxspeed = 16;
INT32 titlescrollyspeed = 0;
UINT32 titlemusicstart = 38749;
boolean titlemapinaction = false;
static INT32 timetonext; // Delay between screen changes
@ -1862,7 +1863,7 @@ luahook:
void F_PlayTitleScreenMusic(void)
{
Music_Loop("title", looptitle);
Music_Seek("title", 38749); // kick in
Music_Seek("title", titlemusicstart); // kick in
Music_Play("title");
}

View file

@ -76,6 +76,7 @@ void F_PlayTitleScreenMusic(void);
extern INT32 finalecount;
extern INT32 titlescrollxspeed;
extern INT32 titlescrollyspeed;
extern UINT32 titlemusicstart;
typedef enum
{