diff --git a/po/ru_pysol.po b/po/ru_pysol.po index 8093060f..4bee0b25 100644 --- a/po/ru_pysol.po +++ b/po/ru_pysol.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "POT-Creation-Date: Sun Aug 19 18:54:00 2007\n" -"PO-Revision-Date: 2007-08-19 18:59+0400\n" +"PO-Revision-Date: 2007-08-24 19:21+0400\n" "Last-Translator: Skomoroh \n" "Language-Team: Russian \n" "MIME-Version: 1.0\n" @@ -829,7 +829,7 @@ msgstr "Король" #: pysollib/games/canfield.py:549 pysollib/games/special/tarock.py:224 #: pysollib/stack.py:1513 pysollib/util.py:78 msgid "Queen" -msgstr "Королева" +msgstr "Дама" #: pysollib/games/curdsandwhey.py:62 msgid "Tableau. Build down by suit or of the same rank." diff --git a/pysollib/games/numerica.py b/pysollib/games/numerica.py index f6763729..e693bd6a 100644 --- a/pysollib/games/numerica.py +++ b/pysollib/games/numerica.py @@ -875,6 +875,57 @@ class DoubleMeasure(Measure): Measure.createGame(self, rows=10) +# /*********************************************************************** +# // Amphibian +# ************************************************************************/ + +class Amphibian(Game): + Hint_Class = Gloaming_Hint + + def createGame(self, rows=5, reserves=4, playcards=15): + # create layout + l, s = Layout(self), self.s + + # set window + self.setSize(l.XM + 8 * l.XS, l.YM + 3*l.YS + playcards*l.YOFFSET) + + # create stacks + x, y = l.XM, l.YM + for i in range(4): + for j in range(2): + s.foundations.append(RK_FoundationStack(x, y, self, + suit=ANY_SUIT)) + x += l.XS + x, y = l.XM+(8-rows)*l.XS/2, l.YM + l.YS + for i in range(rows): + s.rows.append(Gloaming_RowStack(x, y, self, max_accept=1)) + x += l.XS + + x, y = l.XM+(8-reserves-1)*l.XS/2, self.height-l.YS + for i in range(reserves): + s.reserves.append(OpenStack(x, y, self, max_accept=0)) + x += l.XS + + s.talon = TalonStack(x, y, self) + l.createText(s.talon, 'n') + + # define stack-groups + l.defaultStackGroups() + + def startGame(self): + self.startDealSample() + self.s.talon.dealRow(rows=self.s.reserves) + + def fillStack(self, stack): + if stack in self.s.reserves: + for stack in self.s.reserves: + if stack.cards: + return + old_state = self.enterState(self.S_FILL) + self.s.talon.dealRow(rows=self.s.reserves, sound=1) + self.leaveState(old_state) + + # register the game registerGame(GameInfo(257, Numerica, "Numerica", @@ -917,4 +968,6 @@ registerGame(GameInfo(643, Measure, "Measure", GI.GT_NUMERICA | GI.GT_ORIGINAL, 1, 0, GI.SL_MOSTLY_SKILL)) registerGame(GameInfo(644, DoubleMeasure, "Double Measure", GI.GT_NUMERICA | GI.GT_ORIGINAL, 2, 0, GI.SL_MOSTLY_SKILL)) +registerGame(GameInfo(754, Amphibian, "Amphibian", + GI.GT_NUMERICA | GI.GT_ORIGINAL, 2, 0, GI.SL_MOSTLY_SKILL)) diff --git a/pysollib/games/wavemotion.py b/pysollib/games/wavemotion.py index 8940bde8..96a66331 100644 --- a/pysollib/games/wavemotion.py +++ b/pysollib/games/wavemotion.py @@ -94,6 +94,29 @@ class WaveMotion(Game): shallHighlightMatch = Game._shallHighlightMatch_SS +# /*********************************************************************** +# // Flourish +# ************************************************************************/ + +class Flourish(WaveMotion): + RowStack_Class = AC_RowStack + + def createGame(self): + WaveMotion.createGame(self, rows=7, reserves=8, playcards=7) + + def isGameWon(self): + for s in self.s.rows: + if s.cards: + if len(s.cards) != 13 or not isAlternateColorSequence(s.cards): + return False + return True + + shallHighlightMatch = Game._shallHighlightMatch_AC + + + # register the game registerGame(GameInfo(314, WaveMotion, "Wave Motion", - GI.GT_1DECK_TYPE, 1, 0, GI.SL_MOSTLY_SKILL)) + GI.GT_1DECK_TYPE | GI.GT_OPEN, 1, 0, GI.SL_MOSTLY_SKILL)) +registerGame(GameInfo(753, Flourish, "Flourish", + GI.GT_1DECK_TYPE | GI.GT_OPEN | GI.GT_ORIGINAL, 1, 0, GI.SL_MOSTLY_SKILL))