Compare commits
2 commits
29a1f3f4ec
...
f57810163f
Author | SHA1 | Date | |
---|---|---|---|
f57810163f | |||
3575927c85 |
1 changed files with 2 additions and 2 deletions
4
main.py
4
main.py
|
@ -51,7 +51,7 @@ def doRound(turn, canCheat, player, computer):
|
|||
bank += res[1]
|
||||
print(f"Computer roll {rollCounter}:")
|
||||
print(f"Computer rolled a {res[1]}, bank is now {bank}")
|
||||
shouldRoll = fp.randint(0, 1)
|
||||
shouldRoll = fp.randint(0, 1) if (bank+computer < 100) else 0
|
||||
else:
|
||||
rollCounter += 1
|
||||
print(f"Computer roll {rollCounter}:")
|
||||
|
@ -60,7 +60,7 @@ def doRound(turn, canCheat, player, computer):
|
|||
break
|
||||
bank += res[0]
|
||||
print(f"Computer rolled a {res[0]}, bank is now {bank}")
|
||||
shouldRoll = fp.rint(0, 1)
|
||||
shouldRoll = fp.randint(0, 1) if (bank+computer < 100) else 0
|
||||
if not shouldRoll:
|
||||
print(
|
||||
f"Computer stopped rolling after {rollCounter} roll(s), bank was {bank} points{' (!! CHEAT !!)' if cheatFlag else ''}"
|
||||
|
|
Loading…
Reference in a new issue