Compare commits
No commits in common. "b946ad3ddab42255cab16d8bced91a6e1e0cc123" and "18e0ad1dfb40f7834a59147da5c5da1cf5eb342a" have entirely different histories.
b946ad3dda
...
18e0ad1dfb
1 changed files with 7 additions and 35 deletions
42
tools.py
42
tools.py
|
@ -698,7 +698,7 @@ def studio():
|
||||||
tradenormal = []
|
tradenormal = []
|
||||||
tradespecial = []
|
tradespecial = []
|
||||||
for card in colors.cardlist:
|
for card in colors.cardlist:
|
||||||
if card["priority"] == 4:
|
if card["priority"] == 4 and card["dupe"] == False:
|
||||||
if card["colour"] != "sig" and card["colour"] != "limited":
|
if card["colour"] != "sig" and card["colour"] != "limited":
|
||||||
if card["dupe"]:
|
if card["dupe"]:
|
||||||
if len(card["mass"]) == 0:
|
if len(card["mass"]) == 0:
|
||||||
|
@ -785,15 +785,10 @@ def studio():
|
||||||
give.extend(random.sample(tradenormal,needednormal))
|
give.extend(random.sample(tradenormal,needednormal))
|
||||||
if neededspecial > 0:
|
if neededspecial > 0:
|
||||||
give.extend(random.sample(tradespecial,neededspecial))
|
give.extend(random.sample(tradespecial,neededspecial))
|
||||||
allwantch = []
|
if choicewant > 0:
|
||||||
allwantsp = []
|
choicelist = input(str(choicewant) + " choice character cards: ").split(", ")
|
||||||
for card in colors.wantedlist:
|
if specialwant > 0:
|
||||||
if card["colour"] == "special":
|
speciallist = input(str(specialwant) + " choice special cards: ").split(", ")
|
||||||
allwantsp.append(card["name"])
|
|
||||||
else:
|
|
||||||
allwantch.append(card["name"])
|
|
||||||
choicelist = allwantch[:choicewant]
|
|
||||||
speciallist = allwantsp[:specialwant]
|
|
||||||
allwants = []
|
allwants = []
|
||||||
if dupeswant > 1:
|
if dupeswant > 1:
|
||||||
allwants.append(str(dupeswant) + " random cards")
|
allwants.append(str(dupeswant) + " random cards")
|
||||||
|
@ -1476,31 +1471,12 @@ def maketrade():
|
||||||
print("Nothing to trade")
|
print("Nothing to trade")
|
||||||
|
|
||||||
def masteredtoday():
|
def masteredtoday():
|
||||||
mastereddecks = []
|
|
||||||
for deck in colors.decklist:
|
for deck in colors.decklist:
|
||||||
try:
|
try:
|
||||||
if deck["mastered"].date() == datetime.datetime.today().date():
|
if deck["mastered"].date() == datetime.datetime.today().date():
|
||||||
mastereddecks.append(deck["name"])
|
print(deck["name"])
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
if len(mastereddecks) > 0:
|
|
||||||
print(", ".join(mastereddecks))
|
|
||||||
else:
|
|
||||||
print("No decks mastered today")
|
|
||||||
|
|
||||||
def topwant(special=False):
|
|
||||||
wantedch = []
|
|
||||||
wantedsp = []
|
|
||||||
for card in colors.wantedlist:
|
|
||||||
if card["colour"] == "special":
|
|
||||||
wantedsp.append(card["name"])
|
|
||||||
else:
|
|
||||||
wantedch.append(card["name"])
|
|
||||||
showcards = int(input("How many to show? "))
|
|
||||||
if special:
|
|
||||||
print(", ".join(wantedsp[:showcards]))
|
|
||||||
else:
|
|
||||||
print(", ".join(wantedch[:showcards]))
|
|
||||||
|
|
||||||
def swapstation():
|
def swapstation():
|
||||||
swappablemedium = []
|
swappablemedium = []
|
||||||
|
@ -1608,7 +1584,7 @@ if __name__ == "__main__":
|
||||||
index = 0 # adapted from https://stackoverflow.com/a/64536882
|
index = 0 # adapted from https://stackoverflow.com/a/64536882
|
||||||
indexValidList = []
|
indexValidList = []
|
||||||
print("Choose from the list:")
|
print("Choose from the list:")
|
||||||
options = ["Generate next palette portfolio","Generate next monochrome portfolio","Generate Switch It Up request","Generate Swap Station request","Generate Go Fish comment","Generate Release Roulette comment","Generate Riku’s Favors comment","Generate art shop request","Generate art studio request","Check a trade offer","Propose a trade","Get a list of random cards from tradepile (excluding specials)","Get a list of random cards from tradepile (including specials)","Check a card in the collection","Check details of a deck","See decks mastered today","See most wanted character cards","See most wanted special cards","See some statistics about the collection"]
|
options = ["Generate next palette portfolio","Generate next monochrome portfolio","Generate Switch It Up request","Generate Swap Station request","Generate Go Fish comment","Generate Release Roulette comment","Generate Riku’s Favors comment","Generate art shop request","Generate art studio request","Check a trade offer","Propose a trade","Get a list of random cards from tradepile (excluding specials)","Get a list of random cards from tradepile (including specials)","Check a card in the collection","Check details of a deck","See decks mastered today","See some statistics about the collection"]
|
||||||
for optionName in options:
|
for optionName in options:
|
||||||
index = index + 1
|
index = index + 1
|
||||||
indexValidList.extend([options.index(optionName)])
|
indexValidList.extend([options.index(optionName)])
|
||||||
|
@ -1658,9 +1634,5 @@ if __name__ == "__main__":
|
||||||
swapstation()
|
swapstation()
|
||||||
elif chosen == "Generate Release Roulette comment":
|
elif chosen == "Generate Release Roulette comment":
|
||||||
roulette()
|
roulette()
|
||||||
elif chosen == "See most wanted character cards":
|
|
||||||
topwant()
|
|
||||||
elif chosen == "See most wanted special cards":
|
|
||||||
topwant(True)
|
|
||||||
print("\n")
|
print("\n")
|
||||||
input("Press Enter to continue or Ctrl-C to exit")
|
input("Press Enter to continue or Ctrl-C to exit")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue