X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Flibgame%2Fsound.c;h=6ca95ea47de709bce3727f24bed5315fe753550c;hb=7bedd910f0f469c78d51a0c90f679258d5b0ced7;hp=12b01c382b8f1c50cd62403b9ce65317fa9e8840;hpb=c8689f0335cd584d24570046c6eb5a3b75701305;p=rocksndiamonds.git diff --git a/src/libgame/sound.c b/src/libgame/sound.c index 12b01c38..6ca95ea4 100644 --- a/src/libgame/sound.c +++ b/src/libgame/sound.c @@ -166,8 +166,8 @@ static boolean Mixer_ChannelExpired(int channel) if (expire_loop_sounds && IS_LOOP(mixer[channel]) && !IS_MUSIC(mixer[channel]) && - DelayReached(&mixer[channel].playing_starttime, - SOUND_LOOP_EXPIRATION_TIME)) + DelayReachedExt2(&mixer[channel].playing_starttime, + SOUND_LOOP_EXPIRATION_TIME, Counter())) return TRUE; if (!Mix_Playing(channel)) @@ -741,6 +741,16 @@ static MusicInfo *getMusicInfoEntryFromMusicID(int pos) return mus_info[list_pos]; } +char *getSoundInfoEntryFilename(int pos) +{ + SoundInfo *snd_info = getSoundInfoEntryFromSoundID(pos); + + if (snd_info == NULL) + return NULL; + + return getBaseNamePtr(snd_info->source_filename); +} + char *getMusicInfoEntryFilename(int pos) { MusicInfo *mus_info = getMusicInfoEntryFromMusicID(pos); @@ -1103,7 +1113,7 @@ static void ReloadCustomMusic(void) LoadCustomMusic_NoConf(); } -void InitReloadCustomSounds(char *set_identifier) +void InitReloadCustomSounds(void) { if (!audio.sound_available) return; @@ -1111,7 +1121,7 @@ void InitReloadCustomSounds(char *set_identifier) ReloadCustomSounds(); } -void InitReloadCustomMusic(char *set_identifier) +void InitReloadCustomMusic(void) { if (!audio.music_available) return;