X-Git-Url: https://jxself.org/git/?p=super-star-trek.git;a=blobdiff_plain;f=sst.py;h=e2bf5c378288421101bbd0fdce810982e122e7e0;hp=b3264ee904fc341e370e8b4a9016f26f4467db88;hb=5781766e894157bbffe397c4ee3ca5a44d8c5a83;hpb=b4338d649144f9991b77de7d76b6665aa65bae86 diff --git a/sst.py b/sst.py index b3264ee..e2bf5c3 100755 --- a/sst.py +++ b/sst.py @@ -5437,7 +5437,9 @@ def setup(): game.instar = 0 for i in range(GALSIZE): for j in range(GALSIZE): - k = randrange(1, QUADSIZE**2/10) + # Can't have more stars per quadrant than fit in one decimal digit, + # if we do the chart representation will break. + k = randrange(1, min(10, QUADSIZE**2/10)) game.instar += k game.state.galaxy[i][j].stars = k # Locate star bases in galaxy