Show maximum number of randoms
This commit is contained in:
parent
93de038712
commit
fd47368d5a
1 changed files with 1 additions and 1 deletions
2
tools.py
2
tools.py
|
@ -825,7 +825,6 @@ def studio():
|
|||
print("Nothing requested")
|
||||
|
||||
def randoms(specials=False):
|
||||
totalrandoms = int(input("How many? "))
|
||||
pool = []
|
||||
for card in colors.cardlist:
|
||||
if card["priority"] == 4 and card["dupe"] == False and card["colour"] != "sig" and card["colour"] != "limited":
|
||||
|
@ -834,6 +833,7 @@ def randoms(specials=False):
|
|||
else:
|
||||
if card["colour"] != "special":
|
||||
pool.append(card["name"])
|
||||
totalrandoms = int(input("How many? (maximum " + str(len(pool)) + ") "))
|
||||
try:
|
||||
chosen = sorted(random.sample(pool,totalrandoms))
|
||||
print(", ".join(chosen))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue