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

Fixed text positioning for Napoleon Takes/Leaves Moscow.

This commit is contained in:
Joe R 2022-03-22 18:04:10 -04:00
parent 0583f741f0
commit 9273e09841
5 changed files with 51 additions and 13 deletions

View file

@ -11,7 +11,3 @@ Move all cards to the foundations.
Like <a href="derkleinenapoleon.html">Der kleine Napoleon</a>,
but a little bit easier because there are 2 free cells,
each of which is blocked by the corresponding reserve stack.
<h3>Rules</h3>
<p>
<i>[To be written]</i>

View file

@ -0,0 +1,13 @@
<h1>Napoleon Leaves Moscow</h1>
<p>
Napoleon type. 2 decks. 2 redeals.
<h3>Object</h3>
<p>
Move all cards to the foundations.
<h3>Quick Description</h3>
<p>
Like <a href="napoleontakesmoscow.html">Napoleon Takes Moscow</a>,
but sequences of cards of the same suit can be moved between
tableau piles.

View file

@ -0,0 +1,27 @@
<h1>Napoleon Takes Moscow</h1>
<p>
Napoleon type. 2 decks. 2 redeals.
<h3>Object</h3>
<p>
Move all cards to the foundations.
<h3>Rules</h3>
<p>
Cards are dealt to eight piles of four cards each. An
additional sixteen cards are dealt in an additional pile,
containing alternating rows of one and two cards, located in
the center, between the fourth and fifth piles.
<p>
No building is allowed in this center pile, and cards can only
be moved from it if all of their covering cards are removed.
The remaining tableau piles are built down by same suit, with
only individual cards allowed to be moved between tableau piles,
and only kings can fill empty spots.
<p>
Cards can be dealt from the talon one at a time, and moved to the
tableau or foundations. Two redeals are allowed, so you can go
through the talon three times at most.
<p>
The foundations are built up by same suit from ace to king, and the
game is won if all cards are moved to the foundations.

View file

@ -9,6 +9,7 @@ Move all cards to the waste stack.
<h3>Quick Description</h3>
<p>
Like <a href="golf.html">Golf</a>,
but with a different layout. Cards from the fir-trees
can only be moved to the waste if all their covered cards
are gone.
but with a different layout, consisting of three "fir-trees" of
sixteen cards each, dealt in alternating rows of one and two cards.
Cards from the fir-trees can only be moved to the waste if all their
covered cards are gone.

View file

@ -1115,8 +1115,9 @@ class NapoleonTakesMoscow(Game, FirTree_GameMethods):
def createGame(self):
layout, s = Layout(self), self.s
self.setSize(
layout.XM+10*layout.XS, layout.YM+3*layout.YS+15*layout.YOFFSET)
self.setSize(layout.XM + 10 * layout.XS,
layout.YM + 3 * layout.YS + 15 * layout.YOFFSET +
layout.TEXT_HEIGHT)
x, y = layout.XM+layout.XS, layout.YM
for i in range(8):
@ -1133,13 +1134,13 @@ class NapoleonTakesMoscow(Game, FirTree_GameMethods):
x, y = layout.XM+4*layout.XS, layout.YM+layout.YS
s.reserves += self._createFirTree(layout, x, y)
x, y = layout.XM, self.height-layout.YS
x, y = layout.XM, self.height - layout.YS - layout.TEXT_HEIGHT
s.talon = WasteTalonStack(x, y, self, max_rounds=3)
layout.createText(s.talon, 'n')
layout.createRoundText(s.talon, 'nnn')
layout.createText(s.talon, 's')
layout.createRoundText(s.talon, 'n')
x += layout.XS
s.waste = WasteStack(x, y, self)
layout.createText(s.waste, 'n')
layout.createText(s.waste, 's')
# define stack-groups
layout.defaultStackGroups()