Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions generate_build_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,8 @@ def combine_lookups(old_unit_lookup, old_ability_lookup, new_unit_lookup, new_ab
# unit names.
unit_lookup.update(old_unit_lookup)

# When merging old and new ability lookups, prefer to overwrite old cell data with new cell data when merging rows
# in the case of a key clash, but preserve old cell data if cell is empty in new ability lookup table
# When merging old and new ability lookups, prefer to preserve old cell data over new cell data when merging rows
# in the case of a key clash, but use new cell data if old cell data is empty.
for ability_name, commands in new_ability_lookup.items():
if ability_name not in ability_lookup:
ability_lookup[ability_name] = commands
Expand All @@ -183,7 +183,7 @@ def combine_lookups(old_unit_lookup, old_ability_lookup, new_unit_lookup, new_ab
while len(ability_lookup[ability_name]) <= i:
ability_lookup[ability_name].append("")

if command != "":
if ability_lookup[ability_name][i] == "":
ability_lookup[ability_name][i] = command

return unit_lookup, ability_lookup
Expand Down