--- a/QTfrontend/util/namegen.cpp Tue May 14 01:03:23 2019 +0200
+++ b/QTfrontend/util/namegen.cpp Tue May 14 01:10:02 2019 +0200
@@ -228,9 +228,9 @@
team.setHedgehog(HedgehogNumber, hh);
}
-void HWNamegen::teamLocalizedDefaultVoice(HWTeam & team)
+void HWNamegen::teamLocalizedDefaultVoice(HWTeam & team, bool withDLC)
{
- team.setVoicepack(getLocalizedDefaultVoice());
+ team.setVoicepack(getLocalizedDefaultVoice(withDLC));
}
QStringList HWNamegen::dictContents(const QString filename)
@@ -494,13 +494,13 @@
return Voices[rand()%(Voices.size())];
}
-QString HWNamegen::getLocalizedDefaultVoice()
+QString HWNamegen::getLocalizedDefaultVoice(bool withDLC)
{
QStringList entries = DataManager::instance().entryList(
"Sounds/voices",
QDir::Dirs | QDir::NoDotAndDotDot,
QStringList("*"),
- false);
+ withDLC);
QString loc = QLocale().name();
if(entries.contains("Default_" + loc))
--- a/QTfrontend/util/namegen.h Tue May 14 01:03:23 2019 +0200
+++ b/QTfrontend/util/namegen.h Tue May 14 01:10:02 2019 +0200
@@ -38,7 +38,7 @@
static void teamRandomHogNames(HWTeam & team);
static void teamRandomHogName(HWTeam & team, const int HedgehogNumber);
static void teamRandomEverything(HWTeam & team);
- static void teamLocalizedDefaultVoice(HWTeam & team);
+ static void teamLocalizedDefaultVoice(HWTeam & team, bool withDLC = true);
private:
HWNamegen();
@@ -49,7 +49,7 @@
static QString getRandomFort(bool withDLC = true);
static QString getRandomFlag(bool withDLC = true);
static QString getRandomVoice(bool withDLC = true);
- static QString getLocalizedDefaultVoice();
+ static QString getLocalizedDefaultVoice(bool withDLC = true);
static QList<QStringList> TypesTeamnames;
static QList<QStringList> TypesHatnames;