skip nameless traits in unit help pages
This commit is contained in:
parent
ae60ff80e6
commit
dc2b40fd2f
1 changed files with 3 additions and 0 deletions
|
@ -395,6 +395,9 @@ std::string unit_topic_generator::operator()() const {
|
|||
for (const config & trait : traits) {
|
||||
const std::string trait_name = trait["male_name"];
|
||||
std::string lang_trait_name = translation::gettext(trait_name.c_str());
|
||||
if (lang_trait_name.empty()) {
|
||||
continue;
|
||||
}
|
||||
const std::string ref_id = "traits_"+trait["id"].str();
|
||||
((trait["availability"].str() == "musthave") ? must_have_traits : random_traits).push_back(std::make_pair(lang_trait_name, ref_id));
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue