1
0
Fork 0
mirror of https://github.com/shlomif/PySolFC.git synced 2025-04-05 00:02:29 -04:00

Added Tasmanian Patience game.

This commit is contained in:
Joe R 2022-10-23 15:31:19 -04:00
parent 2d8efe9f42
commit ebae446b33
3 changed files with 25 additions and 3 deletions

View file

@ -0,0 +1,13 @@
<h1>Tasmanian Patience</h1>
<p>
Yukon type. 1 deck. Unlimited redeals.
<h3>Object</h3>
<p>
Move all cards to the foundations.
<h3>Quick Description</h3>
<p>
Like <a href="austalianpatience.html">Australian Patience</a>,
but cards are dealt from the talon three at a time, with unlimited
redeals allowed.

View file

@ -544,7 +544,7 @@ class GI:
tuple(range(22217, 22219))),
('fc-2.14', tuple(range(811, 827))),
('fc-2.15', tuple(range(827, 855)) + tuple(range(22400, 22407))),
('dev', tuple(range(855, 857)))
('dev', tuple(range(855, 858)))
)
# deprecated - the correct way is to or a GI.GT_XXX flag

View file

@ -455,6 +455,7 @@ class Panopticon(TenAcross):
# ************************************************************************
# * Australian Patience
# * Tasmanian Patience
# * Raw Prawn
# * Bim Bom
# ************************************************************************
@ -463,11 +464,12 @@ class AustralianPatience(RussianSolitaire):
RowStack_Class = StackWrapper(Yukon_SS_RowStack, base_rank=KING)
def createGame(self, rows=7):
def createGame(self, rows=7, max_rounds=1, num_deal=1):
l, s = Layout(self), self.s
Layout.klondikeLayout(l, rows=rows, waste=1)
self.setSize(l.size[0], l.size[1])
s.talon = WasteTalonStack(l.s.talon.x, l.s.talon.y, self, max_rounds=1)
s.talon = WasteTalonStack(l.s.talon.x, l.s.talon.y, self,
max_rounds=max_rounds, num_deal=num_deal)
s.waste = WasteStack(l.s.waste.x, l.s.waste.y, self)
for r in l.s.foundations:
s.foundations.append(
@ -480,6 +482,11 @@ class AustralianPatience(RussianSolitaire):
self._startDealNumRowsAndDealRowAndCards(3)
class TasmanianPatience(AustralianPatience):
def createGame(self):
AustralianPatience.createGame(self, max_rounds=-1, num_deal=3)
class RawPrawn(AustralianPatience):
RowStack_Class = Yukon_SS_RowStack
@ -809,3 +816,5 @@ registerGame(GameInfo(732, Wave, "Wave",
GI.GT_YUKON | GI.GT_ORIGINAL, 2, 0, GI.SL_BALANCED))
registerGame(GameInfo(826, YukonicPlague, "Yukonic Plague",
GI.GT_YUKON, 1, 0, GI.SL_BALANCED))
registerGame(GameInfo(857, TasmanianPatience, "Tasmanian Patience",
GI.GT_YUKON, 1, -1, GI.SL_BALANCED))