mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-11-17 10:11:12 +00:00
Fix music not updating correctly
This commit is contained in:
parent
8934cf69c7
commit
6c4e4bc457
2 changed files with 11 additions and 10 deletions
|
@ -985,6 +985,10 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
|
||||||
if (S_SoundPlaying(player->mo, sfx_mega)) // But the sound is playing
|
if (S_SoundPlaying(player->mo, sfx_mega)) // But the sound is playing
|
||||||
S_StopSoundByID(player->mo, sfx_mega); // Stop it
|
S_StopSoundByID(player->mo, sfx_mega); // Stop it
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Plays the music after the starting countdown.
|
||||||
|
if (P_IsLocalPlayer(player) && leveltime == 158)
|
||||||
|
S_ChangeMusicInternal(mapmusname, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void K_PlayTauntSound(mobj_t *source)
|
static void K_PlayTauntSound(mobj_t *source)
|
||||||
|
@ -3336,10 +3340,6 @@ void K_drawKartHUD(void)
|
||||||
K_DrawKartPositionNum(stplyr->kartstuff[k_position]);
|
K_DrawKartPositionNum(stplyr->kartstuff[k_position]);
|
||||||
|
|
||||||
K_drawKartSpeedometer();
|
K_drawKartSpeedometer();
|
||||||
|
|
||||||
// Plays the music after the starting countdown. This is here since it checks every frame regularly.
|
|
||||||
if (leveltime > 157 && leveltime < (TICRATE+1)*7)
|
|
||||||
S_ChangeMusicInternal(mapmusname, true);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//}
|
//}
|
||||||
|
|
|
@ -2586,13 +2586,14 @@ boolean P_SetupLevel(boolean skipprecip)
|
||||||
S_StopSounds();
|
S_StopSounds();
|
||||||
S_ClearSfx();
|
S_ClearSfx();
|
||||||
|
|
||||||
// SRB2kart 010217
|
|
||||||
if (leveltime < 157)
|
// As oddly named as this is, this handles music only.
|
||||||
|
// We should be fine starting it here.
|
||||||
|
S_Start();
|
||||||
|
// SRB2 Kart - Yes this is weird, but we don't want the music to start until after the countdown is finished
|
||||||
|
// but we do still need the mapmusname to be changed
|
||||||
|
if (leveltime < 158)
|
||||||
S_StopMusic();
|
S_StopMusic();
|
||||||
if (leveltime > 157)
|
|
||||||
// As oddly named as this is, this handles music only.
|
|
||||||
// We should be fine starting it here.
|
|
||||||
S_Start();
|
|
||||||
|
|
||||||
// Let's fade to black here
|
// Let's fade to black here
|
||||||
// But only if we didn't do the special stage wipe
|
// But only if we didn't do the special stage wipe
|
||||||
|
|
Loading…
Reference in a new issue