ref: a066000012f92f0e98610a6ae975af9f67f242d0
parent: f5ea51bcb1c9dc63f95579ed9c3d3554ab07120a
author: Simon Howard <[email protected]>
date: Sun Oct 21 16:00:54 EDT 2018
music: Show message about filename-based substs. We already show a message if substitutions are loaded from a config file, so show a similar message as well if substitutions are found based on filenames.
--- a/src/i_sdlmusic.c
+++ b/src/i_sdlmusic.c
@@ -943,6 +943,7 @@
{
char *musicdir;
char *path;
+ unsigned int old_music_len;
unsigned int i;
// We can configure the path to music packs using the music_pack_path
@@ -978,6 +979,8 @@
subst_music_len);
}
+ old_music_len = subst_music_len;
+
// Add entries from known filenames list. We add this after those from the
// configuration files, so that the entries here can be overridden.
for (i = 0; i < arrlen(known_filenames); ++i)
@@ -984,6 +987,12 @@
{
AddSubstituteMusic(musicdir, known_filenames[i].hash_prefix,
known_filenames[i].filename);
+ }
+
+ if (subst_music_len > old_music_len)
+ {
+ printf("Configured %i music substitutions based on filename.\n",
+ subst_music_len - old_music_len);
}
free(musicdir);