Skip to content

Commit

Permalink
Extract monster speed descriptions for translation (CleverRaven#52483)
Browse files Browse the repository at this point in the history
  • Loading branch information
BrettDong authored Oct 27, 2021
1 parent 22f4c6b commit 6c15b7a
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions lang/extract_json_strings.py
Original file line number Diff line number Diff line change
Expand Up @@ -1029,9 +1029,15 @@ def extract_snippets(item):
def extract_speed_description(item):
outfile = get_outfile("speed_description")
values = item.get("values", [])
comment = "speed description of monsters"
for value in values:
if 'description' in value:
writestr(outfile, value['description'])
if 'descriptions' in value:
descriptions = value.get("descriptions")
if type(descriptions) is str:
writestr(outfile, descriptions, comment=comment)
elif type(descriptions) is list:
for description in descriptions:
writestr(outfile, description, comment=comment)


def extract_vehicle_part_category(item):
Expand Down

0 comments on commit 6c15b7a

Please sign in to comment.