Changed command line to use class system.
This commit is contained in:
parent
42f55bab97
commit
7e32d849e5
24
sheditor.py
24
sheditor.py
|
@ -560,6 +560,27 @@ def main():
|
||||||
|
|
||||||
soup = BeautifulSoup(full_text, "xml")
|
soup = BeautifulSoup(full_text, "xml")
|
||||||
|
|
||||||
|
item_code_database = ItemCodeDatabase('item_ids.txt')
|
||||||
|
print("Item code database successfully loaded")
|
||||||
|
|
||||||
|
game_data = GameData(soup, item_code_database)
|
||||||
|
game_data.populate()
|
||||||
|
|
||||||
|
if args.buff_chars:
|
||||||
|
game_data.buff_characters()
|
||||||
|
|
||||||
|
if args.add_item:
|
||||||
|
game_data.add_item(args.add_item[0], args.add_item[1])
|
||||||
|
|
||||||
|
if args.money:
|
||||||
|
game_data.add_currency(args.money[0])
|
||||||
|
|
||||||
|
if args.list_ships:
|
||||||
|
game_data.print_summary()
|
||||||
|
|
||||||
|
game_data.writeback()
|
||||||
|
|
||||||
|
"""
|
||||||
# print(soup.prettify())
|
# print(soup.prettify())
|
||||||
if args.buff_chars:
|
if args.buff_chars:
|
||||||
print('Buffing all characters...')
|
print('Buffing all characters...')
|
||||||
|
@ -578,7 +599,8 @@ def main():
|
||||||
|
|
||||||
if args.list_ships:
|
if args.list_ships:
|
||||||
list_ships(soup)
|
list_ships(soup)
|
||||||
|
|
||||||
|
"""
|
||||||
if args.test_gamedata:
|
if args.test_gamedata:
|
||||||
item_code_database = ItemCodeDatabase('item_ids.txt')
|
item_code_database = ItemCodeDatabase('item_ids.txt')
|
||||||
print("Item code database successfully loaded")
|
print("Item code database successfully loaded")
|
||||||
|
|
Loading…
Reference in New Issue