From 6e0ceaf2392075bf68d266c3a48641ac65af8ef6 Mon Sep 17 00:00:00 2001 From: Chris Davoren Date: Sat, 15 Jul 2023 18:18:32 +1000 Subject: [PATCH] Renamed item_ids file to correct extension, minor formatting changes. --- item_ids.txt => item_ids.tsv | 0 sheditor.py | 14 ++++++++------ 2 files changed, 8 insertions(+), 6 deletions(-) rename item_ids.txt => item_ids.tsv (100%) diff --git a/item_ids.txt b/item_ids.tsv similarity index 100% rename from item_ids.txt rename to item_ids.tsv diff --git a/sheditor.py b/sheditor.py index 7d19e00..201198c 100644 --- a/sheditor.py +++ b/sheditor.py @@ -27,11 +27,11 @@ char_skills = { 8: "Shielding", 9: "Operations", 10: "Weapons", - 11: "Unknown-1", + 11: "Unknown-11", 12: "Logistics", # All characters seem to have this but it doesn't show up in the UI - 13: "Unknown-2-enigma", # All characters seem to have this skill but what is it for? + 13: "Unknown-13", # All characters seem to have this skill but what is it for? 14: "Navigation", - 15: "Unknown-3", + 15: "Unknown-15", 16: "Research", 22: "Piloting", # Appears to be the new piloting code? } @@ -170,7 +170,7 @@ class Character: console.print() console.print("Skills:") for i, skill in enumerate(self.skills): - row_string = "{:20} [bright_cyan]{:2}[/]".format(char_skills[skill['id']], skill['level']) + row_string = "{:12} [bright_cyan]{:2}[/]".format(char_skills[skill['id']], skill['level']) if i % 2 == 0: console.print(" [on #222222]{}[/]".format(row_string)) else: @@ -402,7 +402,9 @@ class GameData: continue for character in ship.characters: + console.print() character.print_summary() + console.print() console.print('-----') console.print() @@ -490,7 +492,7 @@ def inventory(soup, add_code, add_quantity): # Load tag names first: id_dict = {} - filename = "item_ids.txt" + filename = "item_ids.tsv" for line in open(filename): result = line.split() code = int(result[0]) @@ -630,7 +632,7 @@ def main(): soup = BeautifulSoup(full_text, "xml") - item_code_database = ItemCodeDatabase('item_ids.txt') + item_code_database = ItemCodeDatabase('item_ids.tsv') print("Item code database successfully loaded.") print()