aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Hodgden <chrhodgden@gmail.com>2024-06-29 16:15:28 +0000
committerChristian Hodgden <chrhodgden@gmail.com>2024-06-29 16:15:28 +0000
commit67a783dfa073b9e6ff4d890df3758ba28d418898 (patch)
tree65a9d49f011c09f41fe47c4389cee2a7f4608161
parent0b191763a375bdc51052e1629ca23db1d0397aee (diff)
previewing other dice-face sequences
-rwxr-xr-xscripts/dice.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/dice.py b/scripts/dice.py
index 00bbd6f..cde7fbb 100755
--- a/scripts/dice.py
+++ b/scripts/dice.py
@@ -58,10 +58,22 @@ class Dice:
if __name__ == '__main__':
alpha = [1, 2, 3, 3, 5, 7]
beta = [0, 2, 4, 4, 5, 6]
+ gamma = [1, 2, 3, 4, 5, 6]
+ sigma = [random.randint(1, 6) for _ in range(6)]
+ delta = [abs(g - s) for g, s in zip(gamma, sigma)]
+ delta = [abs(7 - s) for g, s in zip(gamma, sigma)]
+ # What I really want is to init the dice with a total pip count and then choose the distribution
+ # We probably need a batch dice class
dice_a = Dice(alpha)
dice_b = Dice(beta)
+ dice_g = Dice(gamma)
+ dice_s = Dice(sigma)
+ dice_d = Dice(delta)
a = dice_a.roll()
b = dice_b.roll()
+ g = dice_g.roll()
+ s = dice_s.roll()
+ d = dice_d.roll()
print(a, b, a + b)