mirror of
https://github.com/shlomif/PySolFC.git
synced 2025-04-05 00:02:29 -04:00
extract more code to pysol_cards
This commit is contained in:
parent
3ca47be6e2
commit
c4545ab114
1 changed files with 1 additions and 11 deletions
|
@ -26,7 +26,7 @@
|
||||||
import re
|
import re
|
||||||
|
|
||||||
import pysol_cards
|
import pysol_cards
|
||||||
assert getattr(pysol_cards, 'VERSION', (0, 0, 0)) >= (0, 8, 11), (
|
assert getattr(pysol_cards, 'VERSION', (0, 0, 0)) >= (0, 8, 12), (
|
||||||
"Newer version of https://pypi.org/project/pysol-cards is required.")
|
"Newer version of https://pypi.org/project/pysol-cards is required.")
|
||||||
import pysol_cards.random # noqa: I100
|
import pysol_cards.random # noqa: I100
|
||||||
import pysol_cards.random_base # noqa: I100
|
import pysol_cards.random_base # noqa: I100
|
||||||
|
@ -52,16 +52,6 @@ class MFXRandom(pysol_cards.random.PysolRandom):
|
||||||
def setstate(self, state):
|
def setstate(self, state):
|
||||||
self.seed = state
|
self.seed = state
|
||||||
|
|
||||||
#
|
|
||||||
# implementation
|
|
||||||
#
|
|
||||||
|
|
||||||
def choice(self, seq):
|
|
||||||
return seq[int(self.random() * len(seq))]
|
|
||||||
|
|
||||||
def randrange(self, a, b):
|
|
||||||
return self.randint(a, b-1)
|
|
||||||
|
|
||||||
|
|
||||||
# ************************************************************************
|
# ************************************************************************
|
||||||
# * Linear Congruential random generator
|
# * Linear Congruential random generator
|
||||||
|
|
Loading…
Add table
Reference in a new issue