wmlunits: Do not list abilities without name attributes

This reflects the in-game behavior, which is used to build compound
abilities with only one help entry.
This commit is contained in:
Ignacio R. Morelle 2017-08-15 01:04:59 -03:00
parent c603736111
commit 73857622fc

View file

@ -737,11 +737,13 @@ class HTMLOutput:
continue
already[id] = True
name = T(ability, "name")
if not name:
name = id
if not name:
name = ability.name.decode("utf8")
anames.append(name)
# Only add abilities with a label, since those that lack one
# are normally hidden in the game and used to implement more
# complex ones.
if name:
anames.append(name)
return anames
def get_recursive_attacks(self, this_unit):