Browse Source

Install some formatting for buyout function

KeyMasterOfGozer 2 months ago
parent
commit
7d06f90c29
1 changed files with 4 additions and 2 deletions
  1. 4 2
      db.py

+ 4 - 2
db.py

@@ -70,6 +70,8 @@ def buyout():
     total=0
     cardCount=0
     NeededCards=[]
+    print(f"Cards Needed Today:")
+    print(f'    Name             Needed  Cost')
     for card in MarketCards:
         if 'CRYSTAL' not in Stock[card['card-num']]:
             card['stock']=int(Stock[card['card-num']])
@@ -79,7 +81,7 @@ def buyout():
             NeededCards.append(card)
             total+=card['total-cost']
             cardCount+=card['needed']
-            print(f"{card['card-num']: <3} {card['name']: <20} {card['needed']: >2} {card['total-cost']}")
+            print(f"{card['card-num']: >3} {card['name']: <20} {card['needed']: >2} {round(card['total-cost']): >5}")
     
     print(f"  Remaining Cards: {cardCount}")
-    print(f"Total Gems Needed: {total}")
+    print(f"Total Gems Needed: {round(total)}")