1 Lion, 1 Eagle, 1 Missionary, 1 Admiral, and 2 Princes on 3nd row,
-
14 Pawns on 3rd and 4th rows.
-
-
-
-
The white King is placed on the center of the second row on a black square, the black King being on a white square. The Queen is also placed on the center, beside the King. The Amazon is just behind the King. On the 1st row there is the "animal side" with Eagle, Lion, Buffalo from inside to outside, and the "knighted side" with Amazon, Marshall and Cardinal in this order. On 3rd row, Corporals occupy the six central columns.
-
-
All short-range pieces (and the Ship as well) promote.
-
-
-
Pieces
-
-
King
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Queen
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Bishop
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Knight
-
-
-
-
Moves as in usual Chess. In addition, when a Knight reaches the last row it promotes to a Buffalo.
-
-
-
-
-
Rook
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Elephant
-
-
-
-
As in Shako. In this game, when the Elephant reaches the last row it promotes to a Lion.
-
-
-
-
-
Machine
-
-
-
-
It is an orthogonal counterpart of the Elephant as it moves 1 or 2 cases orthogonally, jumping over the first case if it is occupied. Then, it combines the moves of old Dabbaba and Wazir found in ancient Muslim Chess variants. In this game, when the Machine reaches the last row it promotes to a Lion.
-
-
-
-
-
Lion
-
-
-
-
As in Metamachy, inspired (although with some simplification) by Chu Shogi, the most popular variant of the Japanese Chess. Here the Lion may move as a King (a single step move in any direction), or it may jump to a position two squares away, jumping in any orthogonal or diagonal direction, or alternatively jumping as a Knight in usual Chess. (Then this Lion has the same range but is more restricted than the Lion in Chu Shogi which can move two times in a turn).
-
-
-
-
-
Eagle
-
-
-
-
As in Metamachy, moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex.
-
-
-
-
-
Giraffe
-
-
-
-
a (3,2) jumper, it jumps to the opposite square of a 3x4 rectangle, like an extended Knight. No matter what intermediate squares contain. Note that it always changes the same color of its square. That piece is found in Alfonso X's Grant Acedrex (but its move has been rendered differently by 20th century historians). The same pattern, but with a non-jumping move, is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions.
-
-
-
-
-
Camel
-
-
-
-
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square. When a Camel reaches the last row it promotes to a Buffalo.
-
-
-
-
-
Cannon
-
-
-
-
As in Xiangqi, in Shako and in Metamachy. (Also known as Pao by problemists).
-
-
-
-
-
Bow
-
-
-
-
It is the diagonal counterpart of the Chinese Cannon. It moves like a Bishop and needs an intermediate piece between itself and its victim to capture it. The Bow jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. (Also known as Vao by problemists).
-
-
-
-
-
Bull
-
-
-
-
Jumps to the opposite case of a 3x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always changes the same color of its square. The same move is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions. When a Bull reaches the last row it promotes to a Buffalo.
-
-
-
-
-
Rhinoceros
-
-
-
-
Moves one square vertically or horizontally and then slides away an indefinite number of squares diagonally..
-
-
-
-
-
Marshall
-
-
-
-
It combines the move of Rook and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca and many others like Grand Chess or Gothic Chess. (under many other names: Champion, Guard, Empress, Concubine, Chancellor, etc. The later is sometimes preferred, however it is confusing since Capablanca used it once for R+N and once for B+N. It is an Elephant in Seirawan Chess).
-
-
-
-
-
Cardinal
-
-
-
-
It combines the move of Bishop and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca, Modern and many others like Grand Chess or Gothic Chess. (under many other names: Centaur, Minister, Equerry, Janus, Archbishop, Princess, Chancellor, etc. It is a Hawk in Seirawan Chess).
-
-
-
-
-
Amazon
-
-
-
-
Strongest piece on the board, it combines the move of Queen and Knight. It was used in the Turkish-Indian Grand Chess (as a Giraffe).
-
-
-
-
-
Centaur
-
-
-
-
it is another compound piece that moves as a Knight or a non-royal King.
-
-
-
-
-
Admiral
-
-
-
-
it is another compound piece that moves as a Rook or a non-royal King. That means that it is a Rook that can also step one space diagonally.
-
-
-
-
-
Missionary
-
-
-
-
it is another compound piece that moves as a Bishop or a non-royal King. That means that it is a Bishop that can also step one space orthogonally.
-
-
-
-
-
duchess
-
-
-
-
it is another compound piece that moves as a Bishop or a non-royal King. That means that it is a Bishop that can also step one space orthogonally.
-
-
-
-
-
Promotions table
-
-
-
promotes to
-
-
-
promotes to
-
-
-
promotes to
-
-
-
promotes to
-
-
-
-
promotes to
-
-
-
promotes to
-
-
-
promotes to
-
-
-
promotes to
-
-
-
-
-
-
Initial setup
-
-
The board is a 14 x 14 checkered squares with a white one at the right end of each player.
-
-
-
-
-The pieces are:
-
-The white King is placed on the center of the second row on a black square, the black King being on a white square. The Queen is also placed on the center, beside the King.
-
1 Lion, 1 Eagle 1 Missionary, 1 Admiral, and 2 Princes on 3rd row,
-
14 Pawns on 3rd and 4th rows.
-
-
-
-
The white King is placed on the center of the second row on a black square, the black King being on a white square. The Queen is also placed on the center, beside the King. The Amazon is just behind the King. On the 1st row there is the "animal side" with Eagle, Lion, Buffalo from inside to outside, and the "knighted side" with Amazon, Marshall and Cardinal in this order. On 3rd row, Corporals occupy the six central columns.
-
-
All short-range pieces (and the Ship as well) promote.
-
-
-
Pieces
-
-
King
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Queen
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Bishop
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Knight
-
-
-
-
Moves as in usual Chess. In addition, when a Knight reaches the last row it promotes to a Buffalo.
-
-
-
-
-
Rook
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Elephant
-
-
-
-
As in Shako. In this game, when the Elephant reaches the last row it promotes to a Lion.
-
-
-
-
-
Machine
-
-
-
-
It is an orthogonal counterpart of the Elephant as it moves 1 or 2 cases orthogonally, jumping over the first case if it is occupied. Then, it combines the moves of old Dabbaba and Wazir found in ancient Muslim Chess variants. In this game, when the Machine reaches the last row it promotes to a Lion.
-
-
-
-
-
Lion
-
-
-
-
As in Metamachy, inspired (although with some simplification) by Chu Shogi, the most popular variant of the Japanese Chess. Here the Lion may move as a King (a single step move in any direction), or it may jump to a position two squares away, jumping in any orthogonal or diagonal direction, or alternatively jumping as a Knight in usual Chess. (Then this Lion has the same range but is more restricted than the Lion in Chu Shogi which can move two times in a turn).
-
-
-
-
-
Eagle
-
-
-
-
As in Metamachy, moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex.
-
-
-
-
-
Giraffe
-
-
-
-
a (3,2) jumper, it jumps to the opposite square of a 3x4 rectangle, like an extended Knight. No matter what intermediate squares contain. Note that it always changes the same color of its square. That piece is found in Alfonso X's Grant Acedrex (but its move has been rendered differently by 20th century historians). The same pattern, but with a non-jumping move, is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions.
-
-
-
-
-
Camel
-
-
-
-
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square. When a Camel reaches the last row it promotes to a Buffalo.
-
-
-
-
-
Cannon
-
-
-
-
As in Xiangqi, in Shako and in Metamachy. (Also known as Pao by problemists).
-
-
-
-
-
Archer
-
-
-
-
It is the diagonal counterpart of the Chinese Cannon. It moves like a Bishop and needs an intermediate piece between itself and its victim to capture it. The Archer jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. (Also known as Vao by problemists).
-
-
-
-
-
Buffalo
-
-
-
-
Jumps to the opposite case of a 3x4 rectangle, like an extended Knight. No matter what intermediate cases contain.
-
-
-
-
-
Rhinoceros
-
-
-
-
Moves one square vertically or horizontally and then slides away an indefinite number of squares diagonally..
-
-
-
-
-
Marshall
-
-
-
-
It combines the move of Rook and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca and many others like Grand Chess or Gothic Chess. (under many other names: Champion, Guard, Empress, Concubine, Chancellor, etc. The later is sometimes preferred, however it is confusing since Capablanca used it once for R+N and once for B+N. It is an Elephant in Seirawan Chess).
-
-
-
-
-
Cardinal
-
-
-
-
It combines the move of Bishop and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca, Modern and many others like Grand Chess or Gothic Chess. (under many other names: Centaur, Minister, Equerry, Janus, Archbishop, Princess, Chancellor, etc. It is a Hawk in Seirawan Chess).
-
-
-
-
-
Amazon
-
-
-
-
Strongest piece on the board, it combines the move of Queen and Knight. It was used in the Turkish-Indian Grand Chess (as a Giraffe).
-
-
-
-
-
Centaur
-
-
-
-
it is another compound piece that moves as a Knight or a non-royal King.
-
-
-
-
-
Admiral
-
-
-
-
it is another compound piece that moves as a Rook or a non-royal King. That means that it is a Rook that can also step one space diagonally.
-
-
-
-
-
Prince
-
-
-
-
a non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead.
-
-
-
-
-
Missionary
-
-
-
-
it is another compound piece that moves as a Bishop or a non-royal King. That means that it is a Bishop that can also step one space orthogonally.
-
-
-
-
-
Duchess
-
-
-
-
it moves as a limited Queen, one, two or three squares in any straight directions. When moving two or three squares, it may jump and it does not matter what any intermediate squares contain.
-
-
-
-
-
Sorceress
-
-
-
-
it moves like a Queen and needs an intermediate piece between itself and its victim to capture it. The Sorceress jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. Like the Queen is Bishop + Rook, the Sorceress is Cannon + Archer.
The Champion leaps two spaces in any orthogonal or diagonal direction, or one space in any orthogonal direction. It is a compound of the Alfil, Dababbah, and Wazir. It was introduced in Omega Chess, and it moves the same as it does in that game.
+
+
+
+
+
Wizard
+
+
+
+
The Wizard moves one space diagonally or leaps to a space one file and three ranks away or three files and one rank away. It is a compound of the Ferz and the Camel. It was introduced in Omega Chess, and it moves the same as it does in that game.
+
+
+
+
+
+
Marshall
+
+
+
+
It combines the move of Rook and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca and many others like Grand Chess or Gothic Chess. (under many other names: Champion, Guard, Empress, Concubine, Chancellor, etc. The later is sometimes preferred, however it is confusing since Capablanca used it once for R+N and once for B+N. It is an Elephant in Seirawan Chess).
+
+
+
+
+
Archbishop
+
+
+
+
It combines the move of Bishop and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca, Modern and many others like Grand Chess or Gothic Chess. (under many other names: Centaur, Minister, Equerry, Janus, Archbishop, Princess, Chancellor, etc. It is a Hawk in Seirawan Chess).
+
+
+
+
+
Leo
+
+
+
+
The Leo moves as a Queen but must hop over an intervening piece to capture.
+
+
+
+
+
King
+
+
+
+
Moves as in usual Chess but castle 2 or 3 squares away with the rook.
+
+
+
+
+
Queen
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
Bishop
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
Knight
+
+
+
+
Moves as in usual Chess.
+
+
+
+
+
Rook
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
+
Pawn
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
+
Can move two squares only on their first move, and capture en passant only when the target pawn has just moved two squares.
diff --git a/src/games/chessbase/res/rules/decimal/scirocco-description.html b/src/games/chessbase/res/rules/decimal/scirocco-description.html
new file mode 100644
index 00000000..8ce45dc6
--- /dev/null
+++ b/src/games/chessbase/res/rules/decimal/scirocco-description.html
@@ -0,0 +1,14 @@
+
Scirocco is a large chess variant inspired by historic European and Japanese chess variants.
+
+
Scirocco is remeniscent of Shogi variants from before the invention of piece drops.
+In particular the fact that all pieces can promote without choice for what they become,
+in a zone spanning multiple ranks, gives it a stong Chu-Shogi flavor.
+Yet it also adheres to the European traditions of 8-fold symmetric pieces
+and oblique leaps, and divergent Pawns.
+The weakness of the initial pieces reminds of the Medieval Courier Chess
+and Tamerlane Chess.
+
+
+
Scirocco was invented by Adrian King in 1998-1999,
+and the 'revised' version presented here stems from 2001.
+
diff --git a/src/games/chessbase/res/rules/decimal/scirocco-rules.html b/src/games/chessbase/res/rules/decimal/scirocco-rules.html
new file mode 100644
index 00000000..f1dc9103
--- /dev/null
+++ b/src/games/chessbase/res/rules/decimal/scirocco-rules.html
@@ -0,0 +1,401 @@
+
General rules
+
Scirocco is a chess variant on a 10x10 board.
+Initially each player has 27 pieces of 18 different types.
+Each of these pieces (even the King) has a distinct promoted form,
+moving differently from the initial, unpromoted piece.
+Promotion of a piece is always optional,
+and can be done at the end of any move with it
+that starts or end in the promotion zone
+formed by the farthest three ranks of the board.
+Once promoted a piece cannot unpromote or promote again.
+
+
+A game is won by checkmating or stalemating the opponent,
+or capturing all his non-royal pieces ('baring' the royal).
+The latter finishes the game immediately,
+so that it is safe to leave your King in
+what otherwise would be check after the baring move.
+Baring is thus similar to King capture,
+making your last non-royal effectively royal too.
+
+Repeating a position that occurred before also ends the game.
+The player that made the last move (and thus caused the repetition) then loses,
+unless none of the moves since the previous occurrence of the final position
+by either player attacked anything;
+in that case the game ends in a draw.
+There is no limit on the number of reversible moves;
+the only other way to draw is by mutual agreement.
+
+
Other rules are as in orthodox chess. White starts to play.
+
Unusual aspects
+
+Apart from the promotion rules (which makes Scirocco more like a shogi variant than a chess variant),
+there are several other peculiarities.
+Some pieces can capture like in Checkers, by jumping over an adjacent piece to the empty square behind it.
+Another piece can capture adjacent enemies without moving ('rifle capture');
+the entire move consist of just taking such an enemy piece from the board.
+There are also pieces that induce moves in other friendly pieces instead of being able to capture foes.
+Any friendly piece in the range of such a move inducer can then gets its move repertoire expanded.
+Finally, many pieces are divergent, meaning that they capture in a different way from how they move to empty squares.
+In orthodox Chess only Pawns have this property.
+
+
+
Initial setup
+
+
The board is a 10 x 10 checkered squares with a white one at the right end of each player.
Moves and captures as in orthodox Chess,
+but no initial double-push, and thus no en-passant capture.
+Promotes to Tadpole
+
+
+
Guard
+
+
+
+
Moves one step orthogonally,
+captures one step diagonally.
+Promotes to Zebra.
+
+
+
Wazir
+
+
+
+
Moves and captures one step orthogonally.
+Promotes to Zig.
+
+
+
Firzan
+
+
+
+
Moves and captures one step diagonally.
+Promotes to Zag.
+
+
+
Alfil
+
+
+
+
Moves and captures two steps diagonally
+(possibly jumping over an occupied square).
+Promotes to Bishop.
+
+
+
Dabbaba
+
+
+
+
Moves and captures two steps orthonally
+(possibly jumping over an occupied square).
+Promotes to Genie.
+
+
+
Stork
+
+
+
+
Moves and captures two steps diagonally
+(possibly jumping), or captures one step orthogonally.
+Promotes to Queen.
+
+
Goat
+
+
+
+
Moves and captures two steps orthogonally
+(possibly jumping), or moves without capturing one step diagonally.
+Promotes to Lioness.
+
+
+
+
Commoner
+
+
+
+
Moves and captures like an orthodox King,
+but is not royal.
+Promotes to Wildebeest.
+
+
+
Knight
+
+
+
+
Moves and captures like a Knight in usual Chess.
+Promotes to Rook.
+
+
+
Camel
+
+
+
+
Moves and captures directly to squares
+three steps removed from it in one orthogonal dimension,
+and one step in the other (like a Knight, but landing one step further away).
+Promotes to Squirrel.
+
+
+
Marquis
+
+
+
+
Moves and captures like a Knight,
+or one step orthogonally.
+Promotes to Abbot.
+
+
+
Priest
+
+
+
+
Moves and captures like a Knight,
+ore one step diagonally.
+Promotes to Duke.
+
+
+
Wagon
+
+
+
+
Moves and captures like an orthodox Rook,
+but cannot end on an adjacent square.
+(But it can be blocked there!)
+Promotes to Spider.
+
+
+
Chariot
+
+
+
+
Moves and captures like an orthodox Rook,
+but not farther away than four steps.
+Promotes to Octopus.
+
+
+
Dervish
+
+
+
+
Moves two steps orthogonally or diagonally,
+possibly jumping over an occupied square.
+Cannot capture, but may induce new moves in friendly pieces adjacent to it:
+these can then jump over it to the diametrically opposite square,
+or make one step diagonally provided this ends next to the Dervish.
+These induced moves can both move and capture,
+but they can never be promotions.
+Promotes to Harpy.
+
+
+
Scirocco
+
+
+
+
Moves and captures like an orthodox Bishop,
+or one step orthogonally.
+Promotes to Vulture.
+
+
+
King
+
+
+
+
Moves and captures like an orthodox King.
+Moves that would expose the King to capture are illegal.
+Promotes to Emperor.
+
+
+
Tadpole
+
+
+
+
Promoted Pawn.
+Moves and captures one step diagonally or 3 steps orthogonally
+(jumping over anythin that might be on the two squares in between).
+In addition it can also capture one square orthogonally.
+
+
+
Zebra
+
+
+
+
Promoted Guard.
+Moves and captures diectly to squares
+three steps away in one orthogonal dimension, and two steps in the other.
+(Like a Knight, but one step further diagonally out.)
+
+
+
Zig
+
+
+
+
Promoted Wazir.
+Moves and captures one or two steps diagonally
+(possibly jumping over an occupied square).
+In addition it can capture an adjacent enemy piece
+by jumping (two steps) over it orthogonally to an empty square.
+
+
+
Zag
+
+
+
+
Promoted Ferz.
+Moves and captures one or two steps orthogonally
+(possibly jumping over an occupied square).
+In addition it can capture an adjacent enemy piece
+by jumping (two steps) over it diagonally to an empty square
+(like a King in Checkers).
+
+
+
Bishop
+
+
+
+
Promoted Alfil.
+Moves and captures like an orthodox Bishop.
+
+
+
Genie
+
+
+
+
Promoted Dabbaba.
+Moves and captures like an orthodox Queen, but not farther than 3 squares away.
+In addition it can capture an adjacent enemy piece without moving
+('rifle capture').
+
+
+
Queen
+
+
+
+
Promoted Stork.
+Moves and captures as an orthodox Queen.
+
+
+
Lioness
+
+
+
+
Promoted Goat.
+Moves and captures directly to any square in a 5x5 area around it.
+
+
+
Wildebeest
+
+
+
+
Promoted Commoner.
+Moves and captures like a Knight or a Camel.
+
+
+
Rook
+
+
+
+
Promoted Knight.
+Moves and captures like an orthodox Rook.
+
+
+
Squirrel
+
+
+
+
Promoted Camel.
+Moves and captures directly two steps orthogonally or diagonally
+(possibly jumping over an occupied square),
+or like an orthodox Knight.
+
+
+
Abbot
+
+
+
+
Promoted Marquis.
+Moves and captures like a Knight or like a Bishop,
+but not farther than 4 squares away.
+
+
+
Duke
+
+
+
+
Promoted Priest.
+Moves and captures like a Knight or like a Rook,
+but not farther than 4 squares away.
+
+
+
Spider
+
+
+
+
Promoted Wagon.
+Moves to an empty orthogonally adjacent square,
+possibly continuing from there like a Bishop in any of the two outward directions
+for moving or capturing to more distant destinations.
+
+
+
Octopus
+
+
+
+
Promoted Chariot.
+Moves to an empty diagonally adjacent square,
+possibly continuing from there like a Rook in any of the two outward directions
+for moving or capturing to more distant destinations.
+
+
+
Harpy
+
+
+
+
Promoted Dervish.
+Moves like a Queen, but no farther than 3 steps away.
+The Harpy cannot capture,
+but it induces extra Knight moves on any friendly piece
+on a square it could have reached with this 3-step Queen move
+if it had been empty.
+The induced Knight moves can both move and capture,
+but they can never be promotions.
+
+
+
Vulture
+
+
+
+
Promoted Scirocco.
+Moves like a King or a Bisop, and captures like a King or a Rook.
+(So to adjacent squares it can both move and capture.)
+
+
+
Emperor
+
+
+
+
Promoted King.
+Moves and captures one step orthogonally,
+or two steps in all eight directions (possibly jumping over an occupied square).
+Moves that would expose the Emperor to capture are illegal.
+
+
+
+
diff --git a/src/games/chessbase/demi-credits.html b/src/games/chessbase/res/rules/demi/demi-credits.html
similarity index 100%
rename from src/games/chessbase/demi-credits.html
rename to src/games/chessbase/res/rules/demi/demi-credits.html
diff --git a/src/games/chessbase/demi-description.html b/src/games/chessbase/res/rules/demi/demi-description.html
similarity index 100%
rename from src/games/chessbase/demi-description.html
rename to src/games/chessbase/res/rules/demi/demi-description.html
diff --git a/src/games/chessbase/demi-rules.html b/src/games/chessbase/res/rules/demi/demi-rules.html
similarity index 100%
rename from src/games/chessbase/demi-rules.html
rename to src/games/chessbase/res/rules/demi/demi-rules.html
diff --git a/src/games/chessbase/demi-thumb.png b/src/games/chessbase/res/rules/demi/demi-thumb.png
similarity index 100%
rename from src/games/chessbase/demi-thumb.png
rename to src/games/chessbase/res/rules/demi/demi-thumb.png
diff --git a/src/games/chessbase/devasa-credits.html b/src/games/chessbase/res/rules/devasa/devasa-credits.html
similarity index 100%
rename from src/games/chessbase/devasa-credits.html
rename to src/games/chessbase/res/rules/devasa/devasa-credits.html
diff --git a/src/games/chessbase/devasa-description.html b/src/games/chessbase/res/rules/devasa/devasa-description.html
similarity index 100%
rename from src/games/chessbase/devasa-description.html
rename to src/games/chessbase/res/rules/devasa/devasa-description.html
diff --git a/src/games/chessbase/devasa-rules.html b/src/games/chessbase/res/rules/devasa/devasa-rules.html
similarity index 100%
rename from src/games/chessbase/devasa-rules.html
rename to src/games/chessbase/res/rules/devasa/devasa-rules.html
diff --git a/src/games/chessbase/devasa-thumb.png b/src/games/chessbase/res/rules/devasa/devasa-thumb.png
similarity index 100%
rename from src/games/chessbase/devasa-thumb.png
rename to src/games/chessbase/res/rules/devasa/devasa-thumb.png
diff --git a/src/games/chessbase/res/rules/duodecimal/emir.png b/src/games/chessbase/res/rules/duodecimal/emir.png
new file mode 100644
index 00000000..6c0a2681
Binary files /dev/null and b/src/games/chessbase/res/rules/duodecimal/emir.png differ
diff --git a/src/games/chessbase/leychessalpha-credits.html b/src/games/chessbase/res/rules/duodecimal/leychessalpha-credits.html
similarity index 100%
rename from src/games/chessbase/leychessalpha-credits.html
rename to src/games/chessbase/res/rules/duodecimal/leychessalpha-credits.html
diff --git a/src/games/chessbase/leychessalpha-description.html b/src/games/chessbase/res/rules/duodecimal/leychessalpha-description.html
similarity index 100%
rename from src/games/chessbase/leychessalpha-description.html
rename to src/games/chessbase/res/rules/duodecimal/leychessalpha-description.html
diff --git a/src/games/chessbase/leychessalpha-rules.html b/src/games/chessbase/res/rules/duodecimal/leychessalpha-rules.html
similarity index 60%
rename from src/games/chessbase/leychessalpha-rules.html
rename to src/games/chessbase/res/rules/duodecimal/leychessalpha-rules.html
index e1587a95..80b855d0 100644
--- a/src/games/chessbase/leychessalpha-rules.html
+++ b/src/games/chessbase/res/rules/duodecimal/leychessalpha-rules.html
@@ -1,177 +1,201 @@
+
LeyChessAlpha Rules
Setup
-
+
Pieces
King
-
+
Exactly as in usual Chess.
-
+
Queen
-
+
Exactly as in usual Chess.
-
+
Bishop
-
+
Exactly as in usual Chess.
-
+
Knight
-
+
Moves as in usual Chess.
-
+
Rook
-
+
Exactly as in usual Chess.
-
+
Pawn
-
+
The Pawn is almost similar to usual Chess. There is a difference: it can advance one or two square from ANY position on the board. However, its capturing move is unchanged: one square diagonally forward. As a consequence, the en-passant capture is possible every time the opposite Pawn or Corporal or Prince has advanced two squares.
-
+
Prince
-
+
This piece is simply a non-royal King combined with a Pawn. It can be found in Metamachy and has been inspired by medieval games like the Courier chess , an old chess variant, played in Germany, where it is called "Man". It moves one square in an arbitrary direction, like the King, but without being hindered by check. Here, like the Pawn, he can move without capturing to the second square straight ahead. When the Prince reaches the last row it promotes to an Emperor.
-
+
Elephant
-
+
As in Shako.
-
+
Lion
-
+
As in Metamachy, inspired (although with some simplification) by Chu Shogi, the most popular variant of the Japanese Chess. Here the Lion may move as a King (a single step move in any direction), or it may jump to a position two squares away, jumping in any orthogonal or diagonal direction, or alternatively jumping as a Knight in usual Chess. (Then this Lion has the same range but is more restricted than the Lion in Chu Shogi which can move two times in a turn).
-
+
Eagle
-
+
As in Metamachy, moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex.
-
+
Camel
-
+
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square.
-
+
Cannon
-
+
As in Xiangqi, in Shako and in Metamachy. (Also known as Pao by problemists).
-
+
Chancellor
-
+
It combines the move of Rook and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca and many others like Grand Chess or Gothic Chess. (under many other names: Champion, Guard, Empress, Concubine, Chancellor, etc. The later is sometimes preferred, however it is confusing since Capablanca used it once for R+N and once for B+N. It is an Elephant in Seirawan Chess).
-
+
Cardinal
-
+
It combines the move of Bishop and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca, Modern and many others like Grand Chess or Gothic Chess. (under many other names: Centaur, Minister, Equerry, Janus, Archbishop, Princess, Chancellor, etc. It is a Hawk in Seirawan Chess).
-
+
Commander
-
+
It combines the move of Queen and Knight. It was used in the Turkish-Indian Grand Chess (as a Giraffe).
-
+
Lighthouse
-
+
It combines the Star and the Queen.
-
+
Unicorn
-
+
The Unicorn combines the Camel, Lion and Antelope and additionaly it can jump infinite times like a Knight in the same direction(like the Knightrider).
-
+
Dragon
-
+
The Dragon combines the Queen and the Eagle.
-
+
Emperor
-
+
The Emperor combines the Dragon, Unicorn and Lighthouse. That means, that every Piece is included in the Emperor. You can only get the Emperor, when you promote a Prince.
Promotion
Pawn
-
+
Prince
-
+
diff --git a/src/games/chessbase/leychessalpha-thumb.png b/src/games/chessbase/res/rules/duodecimal/leychessalpha-thumb.png
similarity index 100%
rename from src/games/chessbase/leychessalpha-thumb.png
rename to src/games/chessbase/res/rules/duodecimal/leychessalpha-thumb.png
diff --git a/src/games/chessbase/res/rules/duodecimal/timur-chess-bnf.png b/src/games/chessbase/res/rules/duodecimal/timur-chess-bnf.png
new file mode 100644
index 00000000..5549edd3
Binary files /dev/null and b/src/games/chessbase/res/rules/duodecimal/timur-chess-bnf.png differ
diff --git a/src/games/chessbase/timurid-credits.html b/src/games/chessbase/res/rules/duodecimal/timurid-credits.html
similarity index 82%
rename from src/games/chessbase/timurid-credits.html
rename to src/games/chessbase/res/rules/duodecimal/timurid-credits.html
index 5a39b30d..20536a49 100644
--- a/src/games/chessbase/timurid-credits.html
+++ b/src/games/chessbase/res/rules/duodecimal/timurid-credits.html
@@ -1,6 +1,6 @@
Rules and descriptions: François Houdebert and Jean-Louis Cazaux
diff --git a/src/games/chessbase/res/rules/duodecimal/timurid-description.html b/src/games/chessbase/res/rules/duodecimal/timurid-description.html
new file mode 100644
index 00000000..4276ffec
--- /dev/null
+++ b/src/games/chessbase/res/rules/duodecimal/timurid-description.html
@@ -0,0 +1,20 @@
+
This game is a variant of Tamerlane II.
+
+itself inspired from "Ajâ'ib al-maqdûr fî qissat Timûr" : The wonders of destiny in the story of Tamerlane.
The first step is to choose which variant of the Timurid family you want to play : you can choose
+
+
+
Lion, Queen, Rhinoceros, Snake, Squirrel, Wizard, Phoenix and Emir for the central piece
+
Ships and Griffons for the side pieces
+
+
+
Choosing the griffons/rhinoceros will result in a more aggressive and undoubtedly faster game. The choice of ship/snake will result in a game that favors the quest for promotion.
+
+
diff --git a/src/games/chessbase/res/rules/duodecimal/timurid-parameter-panel.png b/src/games/chessbase/res/rules/duodecimal/timurid-parameter-panel.png
new file mode 100644
index 00000000..dc6b2c71
Binary files /dev/null and b/src/games/chessbase/res/rules/duodecimal/timurid-parameter-panel.png differ
diff --git a/src/games/chessbase/res/rules/duodecimal/timurid-rules.html b/src/games/chessbase/res/rules/duodecimal/timurid-rules.html
new file mode 100644
index 00000000..0a74dc18
--- /dev/null
+++ b/src/games/chessbase/res/rules/duodecimal/timurid-rules.html
@@ -0,0 +1,231 @@
+
+
+
Initial setup
+
+
+
The board has 12 x 12 squares.
+
+
+Initial Position for Wild Babur, one of the possible variant :
+
+
+
+
Pieces
+
Ship
+
+
+
+
Moves one square diagonally and then, goes away of an indefinite number of cases vertically, never horizontally. It can move one square diagonally only. It can not jump and must begin its move with the diagonal step. The Ship can promote to Griffon.
+
+
+
+
+
Griffon
+
+
+
+
Moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement.
+
+
+
+
+
Squirrel
+
+
+
+
Jumps at 2 squares. The Squirrel can promote to Lion.
+
+
+
+
Lion
+
+
+
+
It jumps on any square situated at 1 or 2 squares distance from where it stands.
+
+
+
+
+
+
Snake
+
+
+
+
Moves one square vertically and then, slides away of an indefinite number of squares diagonally. The Ship can promote to Rhinoceros.
+
+
+
+
+
Rhinoceros
+
+
+
+
It moves one square vertically or horizontally and then, slides away of an indefinite number of squares diagonally.
+
+
+
+
+
Wizard
+
+
+
+
The Wizard moves one space diagonally or leaps to a space one file and three ranks away or three files and one rank away. It is a compound of the Ferz and the Camel. It was introduced in Omega Chess, and it moves the same as it does in that game. The Wizard can promote to Emir.
+
+
+
+
+
+
Emir
+
+
+
+
Combines the move of the Camel, the Knight and the ferz.
+
+
+
+
+
+
Admiral
+
+
+
+
it is another compound piece that moves as a Rook or a non-royal King. That means that it is a Rook that can also step one space diagonally.
+
+
+
+
+
Elephant
+
+
+
+
Moves one or two squares diagonally. When an Elephant moves two squares, it is allowed to jump, i.e., the intervening square does not have to be empty. The Elephant moves as the combined Alfil and Firzan (Ferz) from Shatranj, two pieces which were also present in mediaeval Chess and have disappeared with the birth of modern moves for Queen and Bishop.
+
+
+
+
+
Camel
+
+
+
+
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square.
+
+
+
+
+
Cannon
+
+
+
+
moves without taking like a Rook, but it takes by going in a straight horizontal and vertical line and jumping over exactly one piece. When a Cannon takes a piece, there must be exactly one piece between the original and final square of the Cannon's move - this piece may be of either color. (This is identical to the move of the Cannon in Xiangqi.)
+
+
+
+
+
+
Prince
+
+
+
+
A non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to Queen.
+
+
+
+
Pawn
+
+
+
+
Exactly as in usual Chess. Promote to Queen.
+
+
+
+
+
King
+
+
+
+
Moves as in usual Chess, except there is no castling.
Graphic design: Michel gutierrez (@_mig_) and Jérôme Choain (@jcfrog)
+
diff --git a/src/games/chessbase/res/rules/elven/elven-description.html b/src/games/chessbase/res/rules/elven/elven-description.html
new file mode 100644
index 00000000..2e10350a
--- /dev/null
+++ b/src/games/chessbase/res/rules/elven/elven-description.html
@@ -0,0 +1,19 @@
+
Elven Chess is a game on a 10x10 board that supplements the FIDE army with 4 types of new pieces
+
+
+Elven Chess is basically a translation of the historic Japanese game Chu Shogi to a FIDE context,
+shrinking it to a smaller (but still 10x10) board with fewer pieces.
+
+
+Elven Chess involves 13 pieces behind a rank of 10 Pawns.
+The 5 new pieces differ from their orthodox counterparts by also being able to move and capture like a King.
+The strongest of these (the Warlock) is essentially a King that can move (and capture!) twice per turn,
+and is far stronger than a Queen.
+
+
+There is a rule against trading Warlocks easily out of the game,
+forbidding the capture of a Warlock on consecutive moves;
+either the first capture is already forbidden (when recapture on the same square is possible),
+or the second (when that takes place on a different square.-).
+
+
diff --git a/src/games/chessbase/res/rules/elven/elven-initial.jpg b/src/games/chessbase/res/rules/elven/elven-initial.jpg
new file mode 100644
index 00000000..eb88c3b5
Binary files /dev/null and b/src/games/chessbase/res/rules/elven/elven-initial.jpg differ
diff --git a/src/games/chessbase/res/rules/elven/elven-rules.html b/src/games/chessbase/res/rules/elven/elven-rules.html
new file mode 100644
index 00000000..87e995f8
--- /dev/null
+++ b/src/games/chessbase/res/rules/elven/elven-rules.html
@@ -0,0 +1,296 @@
+
+
Differences from orthodox chess
+
Played on a 10x10 board, 4 new fairy piece involved:
+
+
The Wizard (aka Lion): moves and captures like King, up to two times per turn. Can still make the second move when the first was a capture. Can also make the two King moves as a single jump, but must not end up where it started if it doesn't capture.
+
+
+
The Goblin (aka Crowned Rook or Dragon King): moves and captures like King or Rook
+
+
+
The Elf (aka Crowned Rook or Dragon Horse): moves and captures like King or Bishop
+
+
+
The Dwarf (aka Commoner or Man): moves and captures like a King
+
+
+
+
+
+
Inital setup
+
+
+
+
Each player starts with:
+
+
10 Pawns
+
2 Rooks
+
2 Dwarfs
+
2 Knights
+
2 Bishops
+
1 Elf
+
1 Goblin
+
1 Queen
+
1 Lion
+
1 King
+
+
+
+
Castling: yes. King moves 3 steps towards Rook.
+
Double move for Pawns (start): yes, from their starting rank (the 3rd!).
+
"En passant" capture: yes.
+
Promotion: Pawns promote on entering the enemy camp (last 3 ranks),
+but only to orthodox chess pieces (Knight, Bishop, Rook or Queen).
+
Capture restrictions on Wizards:
+A Wizard cannot be captured by a Wizard if pseudo-legal recapture would be possible on the immediately following half-move.
+A Wizard cannot be captured on the half-move immediately after a Wizard was captured.
Chess is a game played by two people on a chessboard, with sixteen pieces (of six types) for each player. Each type of piece moves in a distinct way.
+The goal of the game is to checkmate, i.e. to threaten the opponent's king with inevitable capture. In addition, there are several ways that a game can end in a draw.
+
+
Initial setup
+
+
+
Chess is played on a chessboard, a square board divided into 64 squares (eight-by-eight) of alternating color, which is similar to that used in
+draughts (checkers). No matter what the actual colors of the board, the lighter-colored squares are called "light" or "white", and the darker-colored squares
+are called "dark" or "black". Sixteen "white" and sixteen "black" pieces are placed on the board at the beginning of the game. The board is placed so that a
+white square is in each player's near-right corner.
+
+
Each player controls sixteen pieces:
+
+
+
+
Name
Number
White Symbols
Black Symbols
+
+
+
King
+
1
+
+
+
+
+
Queen
+
1
+
+
+
+
+
Rook
+
2
+
+
+
+
+
Bishop
+
2
+
+
+
+
+
Knight
+
2
+
+
+
+
+
Pawn
+
8
+
+
+
+
+
+
At the beginning of the game, the pieces are arranged as shown in the diagram. The second row from the player contains the eight pawns;
+the row nearest the player contains the remaining pieces. Popular phrases used to remember the setup, often heard in beginners' clubs,
+are "queen on her own color" and "white on right". The latter refers to setting up the board so that the square closest to each player's right
+is white.
+
+
Play of the game
+
+
The player controlling the white army is named "White"; the player controlling the black pieces is named "Black". White moves first,
+then players alternate moves. Making a move is required; it is not legal to skip a move, even when having to move is detrimental. Play
+continues until a king is checkmated, a player resigns, or a draw is declared, as explained below. In addition, if the game is being played
+under a time control players who exceed their time limit lose the game.
+
+
Movement
+
+
Basic moves
+
+
Each chess piece has its own method of movement. Moves are made to vacant squares except when capturing an opponent's piece.
+
+
With the exception of any movement of the knight and the occasional castling maneuver, pieces cannot jump over each other. When a piece is
+captured (or taken), the attacking piece replaces the enemy piece on its square (en passant being the only exception). The captured piece is
+thus removed from the game and may not be returned to play for the remainder of the game. The king can be put in check but cannot be
+captured (see below).
+
+
+
King
+
+
The king can move exactly one square horizontally, vertically, or diagonally. Only once per player, per game, is a king allowed to make a
+ special move known as castling (see below).
+
+
+
Rooks
+
+
The rook moves any number of vacant squares vertically or horizontally. It also is moved while castling.
+
+
+
Bishops
+
+
The bishop moves any number of vacant squares in any diagonal direction.
+
+
+
Queen
+
+
The queen can move any number of vacant squares diagonally, horizontally, or vertically.
+
+
+
Knights
+
+
The knight moves to the nearest square not on the same rank, file, or diagonal. In other words, the knight moves
+two squares horizontally then one square vertically, or one square horizontally then two squares vertically. Its move is not
+blocked by other pieces: it jumps to the new location.
+
+
+
Pawns
+
+
Pawns have the most complex rules of movement:
+
+
A pawn can move forward one square, if that square is unoccupied. If it has not yet moved, each pawn has the option of moving two squares
+forward provided both squares in front of the pawn are unoccupied. A pawn cannot move backwards.
+
Pawns are the only pieces that capture differently from how they move. They can capture an enemy piece on either of the two spaces adjacent to the space in front of them (i.e., the two squares diagonally in front of them) but cannot move to these spaces if they are vacant.
+
The pawn is also involved in the two special moves en passant and promotion.
+
+
+
Castling
+
+
Castling consists of moving the king two squares towards a rook, then placing the rook on the other side of the king, adjacent to it.
+Castling is only permissible if all of the following conditions hold:
+
+
+
The king and rook involved in castling must not have previously moved;
+
There must be no pieces between the king and the rook;
+
The king may not currently be in check, nor may the king pass through or end up in a square that is under attack by an enemy piece (though the
+rook is permitted to be under attack and to pass over an attacked square);
+
+
+
+
+
+
+
+
En passant
+
+
+
+
If player A's pawn moves forward two squares and player B has a pawn on its fifth rank on an adjacent file,
+B's pawn can capture A's pawn as if A's pawn had only moved one square. This capture can only be made on the immediately
+subsequent move. In this example, if the white pawn moves from a2 to a4, the black pawn on b4 can capture it en passant, ending up on a3.
+
+
Pawn promotion
+
+
If a pawn advances to its eighth rank, it is then promoted (converted) to a queen, rook, bishop, or knight of the same color, the choice
+being at the discretion of its player (a queen is usually chosen). The choice is not limited to previously captured pieces. Hence it is
+theoretically possible for a player to have up to nine queens or up to ten rooks, bishops, or knights if all of their pawns are promoted.
+If the desired piece is not available, the player should call the arbiter to provide the piece.
+
+
Check
+
+
+
+
A king is in check when it is under attack by one or more enemy pieces. A piece unable to move because it would place its own king in check
+(it is pinned against its own king) may still deliver check to the opposing player.
+
+
A player may not make any move which places or leaves his king in check. The possible ways to get out of check are:
+
+
+
+
Move the king to a square where it is not threatened.
+
Capture the threatening piece (possibly with the king).
+
Block the check by placing a piece between the king and the opponent's threatening piece.
+
+
+
End of the game
+
+
Checkmate
+
+
+
+
If a player's king is placed in check and there is no legal move that player can make to escape check, then the king is said to be checkmated,
+the game ends, and that player loses. Unlike other pieces, the king is never actually captured or removed from the board because checkmate ends
+the game.
+
+
The diagram shows a typical checkmate position. The white king is threatened by the black queen; every square to which the king could move is
+ also threatened; it cannot capture the queen, because it would then be threatened by the rook.
+
+
Draws
+
+
+
+
The game ends in a draw if any of these conditions occur:
+
+
The game is automatically a draw if the player to move is not in check but has no legal move. This situation is called a stalemate.
+ An example of such a position is shown in the diagram to the right.
+
The game is immediately drawn when there is no possibility of checkmate for either side with any series of legal moves. This draw is
+ often due to insufficient material, including the endgames
+
+
king against king;
+
king against king and bishop;
+
king against king and knight;
+
king and bishop against king and bishop, with both bishops on diagonals of the same color.
+
+
+
Both players agree to a draw after one of the players makes such an offer.
+
+
+
The player having the move may claim a draw by declaring that one of the following conditions exists, or by declaring an intention to
+make a move which will bring about one of these conditions:
+
+
+
Fifty-move rule: There has been no capture or pawn move in the last fifty moves by each player.
+
Threefold repetition: The same board position has occurred three times with the same player to move and all pieces having the same
+rights to move, including the right to castle or capture en passant.
+
+
+
If the claim is proven true, the game is drawn.
+
+
At one time, if a player was able to check the opposing king continually (perpetual check) and the player indicated their intention to do so,
+the game was drawn. This rule is no longer in effect; however, players will usually agree to a draw in such a situation, since either the rule on
+threefold repetition or the fifty-move rule will eventually be applicable.
diff --git a/src/games/chessbase/res/rules/elven/elven-thumb.png b/src/games/chessbase/res/rules/elven/elven-thumb.png
new file mode 100644
index 00000000..619da67f
Binary files /dev/null and b/src/games/chessbase/res/rules/elven/elven-thumb.png differ
diff --git a/src/games/chessbase/res/rules/fairy/admiral.png b/src/games/chessbase/res/rules/fairy/admiral.png
new file mode 100644
index 00000000..8abda8ff
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/admiral.png differ
diff --git a/src/games/chessbase/res/rules/fairy/antelope.png b/src/games/chessbase/res/rules/fairy/antelope.png
new file mode 100644
index 00000000..7cf2c261
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/antelope.png differ
diff --git a/src/games/chessbase/res/rules/fairy/axe.png b/src/games/chessbase/res/rules/fairy/axe.png
new file mode 100644
index 00000000..4aa230bd
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/axe.png differ
diff --git a/src/games/chessbase/res/rules/fairy/bishop.png b/src/games/chessbase/res/rules/fairy/bishop.png
new file mode 100644
index 00000000..ab803e3d
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/bishop.png differ
diff --git a/src/games/chessbase/res/rules/fairy/bow.png b/src/games/chessbase/res/rules/fairy/bow.png
new file mode 100644
index 00000000..7aa4ccb0
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/bow.png differ
diff --git a/src/games/chessbase/res/rules/fairy/buffalo.png b/src/games/chessbase/res/rules/fairy/buffalo.png
new file mode 100644
index 00000000..00e91187
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/buffalo.png differ
diff --git a/src/games/chessbase/res/rules/fairy/bull.png b/src/games/chessbase/res/rules/fairy/bull.png
new file mode 100644
index 00000000..d0ab2349
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/bull.png differ
diff --git a/src/games/chessbase/res/rules/fairy/caliph.png b/src/games/chessbase/res/rules/fairy/caliph.png
new file mode 100644
index 00000000..da3ea484
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/caliph.png differ
diff --git a/src/games/chessbase/res/rules/fairy/cannon.png b/src/games/chessbase/res/rules/fairy/cannon.png
new file mode 100644
index 00000000..b6c7edc6
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/cannon.png differ
diff --git a/src/games/chessbase/res/rules/fairy/cannon2.png b/src/games/chessbase/res/rules/fairy/cannon2.png
new file mode 100644
index 00000000..b6937f42
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/cannon2.png differ
diff --git a/src/games/chessbase/res/rules/fairy/champion.png b/src/games/chessbase/res/rules/fairy/champion.png
new file mode 100644
index 00000000..fbfb91eb
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/champion.png differ
diff --git a/src/games/chessbase/res/rules/fairy/cobra.png b/src/games/chessbase/res/rules/fairy/cobra.png
new file mode 100644
index 00000000..48dd2526
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/cobra.png differ
diff --git a/src/games/chessbase/res/rules/fairy/corporal.png b/src/games/chessbase/res/rules/fairy/corporal.png
new file mode 100644
index 00000000..31f6adaa
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/corporal.png differ
diff --git a/src/games/chessbase/res/rules/fairy/crowned-bishop.png b/src/games/chessbase/res/rules/fairy/crowned-bishop.png
new file mode 100644
index 00000000..04d1216a
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/crowned-bishop.png differ
diff --git a/src/games/chessbase/res/rules/fairy/crowned-knight.png b/src/games/chessbase/res/rules/fairy/crowned-knight.png
new file mode 100644
index 00000000..188f64e1
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/crowned-knight.png differ
diff --git a/src/games/chessbase/res/rules/fairy/crowned-rook.png b/src/games/chessbase/res/rules/fairy/crowned-rook.png
index e2440019..41962bb2 100644
Binary files a/src/games/chessbase/res/rules/fairy/crowned-rook.png and b/src/games/chessbase/res/rules/fairy/crowned-rook.png differ
diff --git a/src/games/chessbase/res/rules/fairy/eagle.png b/src/games/chessbase/res/rules/fairy/eagle.png
new file mode 100644
index 00000000..35c23d29
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/eagle.png differ
diff --git a/src/games/chessbase/res/rules/fairy/ferz-knight.png b/src/games/chessbase/res/rules/fairy/ferz-knight.png
new file mode 100644
index 00000000..02ab8e04
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/ferz-knight.png differ
diff --git a/src/games/chessbase/res/rules/fairy/ferz.png b/src/games/chessbase/res/rules/fairy/ferz.png
new file mode 100644
index 00000000..1b9d5693
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/ferz.png differ
diff --git a/src/games/chessbase/res/rules/fairy/flying-bishop.png b/src/games/chessbase/res/rules/fairy/flying-bishop.png
new file mode 100644
index 00000000..5c008926
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/flying-bishop.png differ
diff --git a/src/games/chessbase/res/rules/fairy/flying-queen.png b/src/games/chessbase/res/rules/fairy/flying-queen.png
new file mode 100644
index 00000000..5d7ae81b
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/flying-queen.png differ
diff --git a/src/games/chessbase/res/rules/fairy/flying-rook.png b/src/games/chessbase/res/rules/fairy/flying-rook.png
new file mode 100644
index 00000000..b9a2e47f
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/flying-rook.png differ
diff --git a/src/games/chessbase/res/rules/fairy/flying-saint.png b/src/games/chessbase/res/rules/fairy/flying-saint.png
new file mode 100644
index 00000000..00d0b3e3
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/flying-saint.png differ
diff --git a/src/games/chessbase/res/rules/fairy/gate.png b/src/games/chessbase/res/rules/fairy/gate.png
new file mode 100644
index 00000000..49fc1fbf
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/gate.png differ
diff --git a/src/games/chessbase/res/rules/fairy/giraffe.png b/src/games/chessbase/res/rules/fairy/giraffe.png
new file mode 100644
index 00000000..8c9eb56d
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/giraffe.png differ
diff --git a/src/games/chessbase/res/rules/fairy/goat.png b/src/games/chessbase/res/rules/fairy/goat.png
new file mode 100644
index 00000000..e5425161
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/goat.png differ
diff --git a/src/games/chessbase/res/rules/fairy/gold.png b/src/games/chessbase/res/rules/fairy/gold.png
new file mode 100644
index 00000000..c9a0cc7d
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/gold.png differ
diff --git a/src/games/chessbase/res/rules/fairy/griffon.png b/src/games/chessbase/res/rules/fairy/griffon.png
new file mode 100644
index 00000000..13d6ab02
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/griffon.png differ
diff --git a/src/games/chessbase/res/rules/fairy/hawk.png b/src/games/chessbase/res/rules/fairy/hawk.png
new file mode 100644
index 00000000..bbc9ccbe
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/hawk.png differ
diff --git a/src/games/chessbase/res/rules/fairy/hoplit.png b/src/games/chessbase/res/rules/fairy/hoplit.png
new file mode 100644
index 00000000..32a6c2cb
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/hoplit.png differ
diff --git a/src/games/chessbase/res/rules/fairy/hoplit2.png b/src/games/chessbase/res/rules/fairy/hoplit2.png
new file mode 100644
index 00000000..b7f5ec19
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/hoplit2.png differ
diff --git a/src/games/chessbase/res/rules/fairy/king.png b/src/games/chessbase/res/rules/fairy/king.png
new file mode 100644
index 00000000..814bc8f2
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/king.png differ
diff --git a/src/games/chessbase/res/rules/fairy/knight.png b/src/games/chessbase/res/rules/fairy/knight.png
new file mode 100644
index 00000000..d00956f9
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/knight.png differ
diff --git a/src/games/chessbase/res/rules/fairy/leopard.png b/src/games/chessbase/res/rules/fairy/leopard.png
new file mode 100644
index 00000000..e1b3708c
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/leopard.png differ
diff --git a/src/games/chessbase/res/rules/fairy/lion.png b/src/games/chessbase/res/rules/fairy/lion.png
new file mode 100644
index 00000000..6c41284c
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/lion.png differ
diff --git a/src/games/chessbase/res/rules/fairy/machine.png b/src/games/chessbase/res/rules/fairy/machine.png
new file mode 100644
index 00000000..2da2bbe0
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/machine.png differ
diff --git a/src/games/chessbase/res/rules/fairy/mammoth.png b/src/games/chessbase/res/rules/fairy/mammoth.png
new file mode 100644
index 00000000..3ff65b5b
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/mammoth.png differ
diff --git a/src/games/chessbase/res/rules/fairy/man.png b/src/games/chessbase/res/rules/fairy/man.png
new file mode 100644
index 00000000..589b92ae
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/man.png differ
diff --git a/src/games/chessbase/res/rules/fairy/nightrider.png b/src/games/chessbase/res/rules/fairy/nightrider.png
new file mode 100644
index 00000000..57c98bbd
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/nightrider.png differ
diff --git a/src/games/chessbase/res/rules/fairy/pawn.png b/src/games/chessbase/res/rules/fairy/pawn.png
new file mode 100644
index 00000000..161848fa
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/pawn.png differ
diff --git a/src/games/chessbase/res/rules/fairy/phoenix.png b/src/games/chessbase/res/rules/fairy/phoenix.png
new file mode 100644
index 00000000..89b74d63
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/phoenix.png differ
diff --git a/src/games/chessbase/res/rules/fairy/prince.png b/src/games/chessbase/res/rules/fairy/prince.png
new file mode 100644
index 00000000..41bc424a
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/prince.png differ
diff --git a/src/games/chessbase/res/rules/fairy/proper-crowned-rook.png b/src/games/chessbase/res/rules/fairy/proper-crowned-rook.png
new file mode 100644
index 00000000..e2440019
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/proper-crowned-rook.png differ
diff --git a/src/games/chessbase/res/rules/fairy/queen.png b/src/games/chessbase/res/rules/fairy/queen.png
new file mode 100644
index 00000000..f739cb73
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/queen.png differ
diff --git a/src/games/chessbase/res/rules/fairy/ram.png b/src/games/chessbase/res/rules/fairy/ram.png
new file mode 100644
index 00000000..88c6be1a
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/ram.png differ
diff --git a/src/games/chessbase/res/rules/fairy/rhino.png b/src/games/chessbase/res/rules/fairy/rhino.png
new file mode 100644
index 00000000..c7640e27
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/rhino.png differ
diff --git a/src/games/chessbase/res/rules/fairy/rhino2.png b/src/games/chessbase/res/rules/fairy/rhino2.png
new file mode 100644
index 00000000..f08a10db
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/rhino2.png differ
diff --git a/src/games/chessbase/res/rules/fairy/rook.png b/src/games/chessbase/res/rules/fairy/rook.png
new file mode 100644
index 00000000..c24d2a2e
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/rook.png differ
diff --git a/src/games/chessbase/res/rules/fairy/saint.png b/src/games/chessbase/res/rules/fairy/saint.png
new file mode 100644
index 00000000..f4729683
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/saint.png differ
diff --git a/src/games/chessbase/res/rules/fairy/samurai.png b/src/games/chessbase/res/rules/fairy/samurai.png
new file mode 100644
index 00000000..ef715a20
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/samurai.png differ
diff --git a/src/games/chessbase/res/rules/fairy/ship.png b/src/games/chessbase/res/rules/fairy/ship.png
new file mode 100644
index 00000000..1f4654c3
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/ship.png differ
diff --git a/src/games/chessbase/res/rules/fairy/silver.png b/src/games/chessbase/res/rules/fairy/silver.png
new file mode 100644
index 00000000..81cdada9
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/silver.png differ
diff --git a/src/games/chessbase/res/rules/fairy/small-bishop.png b/src/games/chessbase/res/rules/fairy/small-bishop.png
new file mode 100644
index 00000000..75997733
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/small-bishop.png differ
diff --git a/src/games/chessbase/res/rules/fairy/small-rook.png b/src/games/chessbase/res/rules/fairy/small-rook.png
new file mode 100644
index 00000000..812f678c
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/small-rook.png differ
diff --git a/src/games/chessbase/res/rules/fairy/spider.png b/src/games/chessbase/res/rules/fairy/spider.png
new file mode 100644
index 00000000..69091518
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/spider.png differ
diff --git a/src/games/chessbase/res/rules/fairy/squirrel.png b/src/games/chessbase/res/rules/fairy/squirrel.png
new file mode 100644
index 00000000..2b73e3b2
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/squirrel.png differ
diff --git a/src/games/chessbase/res/rules/fairy/star.png b/src/games/chessbase/res/rules/fairy/star.png
new file mode 100644
index 00000000..7a2e617b
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/star.png differ
diff --git a/src/games/chessbase/res/rules/fairy/stork.png b/src/games/chessbase/res/rules/fairy/stork.png
new file mode 100644
index 00000000..df1539e1
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/stork.png differ
diff --git a/src/games/chessbase/res/rules/fairy/terror.png b/src/games/chessbase/res/rules/fairy/terror.png
new file mode 100644
index 00000000..2ede2baf
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/terror.png differ
diff --git a/src/games/chessbase/res/rules/fairy/wazir-knight.png b/src/games/chessbase/res/rules/fairy/wazir-knight.png
new file mode 100644
index 00000000..ee9a0be5
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/wazir-knight.png differ
diff --git a/src/games/chessbase/res/rules/fairy/wazir.png b/src/games/chessbase/res/rules/fairy/wazir.png
new file mode 100644
index 00000000..7628c814
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/wazir.png differ
diff --git a/src/games/chessbase/res/rules/fairy/wizard.png b/src/games/chessbase/res/rules/fairy/wizard.png
new file mode 100644
index 00000000..b42b2e99
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/wizard.png differ
diff --git a/src/games/chessbase/res/rules/fairy/wolf.png b/src/games/chessbase/res/rules/fairy/wolf.png
new file mode 100644
index 00000000..fc17e621
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/wolf.png differ
diff --git a/src/games/chessbase/res/rules/fairy/zebra.png b/src/games/chessbase/res/rules/fairy/zebra.png
new file mode 100644
index 00000000..502d7975
Binary files /dev/null and b/src/games/chessbase/res/rules/fairy/zebra.png differ
diff --git a/src/games/chessbase/chess960-credits.html b/src/games/chessbase/res/rules/famous/chess960-credits.html
similarity index 100%
rename from src/games/chessbase/chess960-credits.html
rename to src/games/chessbase/res/rules/famous/chess960-credits.html
diff --git a/src/games/chessbase/chess960-description.html b/src/games/chessbase/res/rules/famous/chess960-description.html
similarity index 100%
rename from src/games/chessbase/chess960-description.html
rename to src/games/chessbase/res/rules/famous/chess960-description.html
diff --git a/src/games/chessbase/chess960-rules.html b/src/games/chessbase/res/rules/famous/chess960-rules.html
similarity index 100%
rename from src/games/chessbase/chess960-rules.html
rename to src/games/chessbase/res/rules/famous/chess960-rules.html
diff --git a/src/games/chessbase/chess960-thumb.png b/src/games/chessbase/res/rules/famous/chess960-thumb.png
similarity index 100%
rename from src/games/chessbase/chess960-thumb.png
rename to src/games/chessbase/res/rules/famous/chess960-thumb.png
diff --git a/src/games/chessbase/credits-fr.html b/src/games/chessbase/res/rules/famous/credits-fr.html
similarity index 100%
rename from src/games/chessbase/credits-fr.html
rename to src/games/chessbase/res/rules/famous/credits-fr.html
diff --git a/src/games/chessbase/credits.html b/src/games/chessbase/res/rules/famous/credits.html
similarity index 100%
rename from src/games/chessbase/credits.html
rename to src/games/chessbase/res/rules/famous/credits.html
diff --git a/src/games/chessbase/knight-thumbnail.png b/src/games/chessbase/res/rules/famous/knight-thumbnail.png
similarity index 100%
rename from src/games/chessbase/knight-thumbnail.png
rename to src/games/chessbase/res/rules/famous/knight-thumbnail.png
diff --git a/src/games/chessbase/rules-fr.html b/src/games/chessbase/res/rules/famous/rules-fr.html
similarity index 100%
rename from src/games/chessbase/rules-fr.html
rename to src/games/chessbase/res/rules/famous/rules-fr.html
diff --git a/src/games/chessbase/rules.html b/src/games/chessbase/res/rules/famous/rules.html
similarity index 100%
rename from src/games/chessbase/rules.html
rename to src/games/chessbase/res/rules/famous/rules.html
diff --git a/src/games/chessbase/bigorra-description-fr.html b/src/games/chessbase/res/rules/fantasticXIII/bigorra-description-fr.html
similarity index 100%
rename from src/games/chessbase/bigorra-description-fr.html
rename to src/games/chessbase/res/rules/fantasticXIII/bigorra-description-fr.html
diff --git a/src/games/chessbase/bigorra-description.html b/src/games/chessbase/res/rules/fantasticXIII/bigorra-description.html
similarity index 100%
rename from src/games/chessbase/bigorra-description.html
rename to src/games/chessbase/res/rules/fantasticXIII/bigorra-description.html
diff --git a/src/games/chessbase/res/rules/fantasticXIII/bigorra-rules-fr.html b/src/games/chessbase/res/rules/fantasticXIII/bigorra-rules-fr.html
new file mode 100644
index 00000000..7627699e
--- /dev/null
+++ b/src/games/chessbase/res/rules/fantasticXIII/bigorra-rules-fr.html
@@ -0,0 +1,320 @@
+
+
+
Cette pièce peut apparaître par la promotion d’un pion, d’un prince ou d’un Troll. Elle peut sauter à 2 ou 3 cases de distance.
+
+.
+
+
+
+
+
Promotions
+
+
+
+
promu en
+
+
+
promu en
+
+
+
promu en
+
+
+
+
promu en
+
+
+
+
promu en
+
+
+
+
promu en
+
+
+
promu en
+
+
+
promu en
+
+
+
diff --git a/src/games/chessbase/bigorra-rules.html b/src/games/chessbase/res/rules/fantasticXIII/bigorra-rules.html
similarity index 82%
rename from src/games/chessbase/bigorra-rules.html
rename to src/games/chessbase/res/rules/fantasticXIII/bigorra-rules.html
index b4361570..3330d217 100644
--- a/src/games/chessbase/bigorra-rules.html
+++ b/src/games/chessbase/res/rules/fantasticXIII/bigorra-rules.html
@@ -28,7 +28,7 @@
Initial setup
The board has 16 x 16 squares.
-
+
@@ -36,7 +36,7 @@
Pieces
King
-
+
Moves as in usual Chess, except there is no castling.
@@ -45,7 +45,7 @@
King
Snake
-
+
Moves one square vertically and then, slides away of an indefinite number of squares diagonally. It can not jump and the unobstructed path must start with the vertical movement.
@@ -54,7 +54,7 @@
Snake
Ship
-
+
Moves one square diagonally and then, goes away of an indefinite number of cases vertically, never horizontally.
@@ -63,7 +63,7 @@
Ship
Mammoth
-
+
Steps horizontally, vertically or diagonally one or two squares, leaping over the intermediate square if it is occupied
@@ -72,7 +72,7 @@
Mammoth
Squirrel
-
+
Jumps at 2 squares
@@ -82,7 +82,7 @@
Squirrel
Cheetah
-
+
Jumps at 3 squares
@@ -91,7 +91,7 @@
Cheetah
Troll
-
+
Makes a 3-step orthogonal or diagonal jump, no matter what any intermediate square contains. In addition, it moves 1 step forward and captures 1 step diagonally forward (like a Pawn). This permits the Troll to reach any square on the board. It can promote to wolf only when it moves like a Pawn, never by jumping 3 squares
@@ -100,7 +100,7 @@
Troll
Prince
-
+
A non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to wolf.
@@ -109,7 +109,7 @@
Prince
Pawn
-
+
Moves straight forward one or two square from any position on the board, without capturing. It captures one square diagonally forward. As a consequence, the en-passant capture is possible every time an opposite Pawn or Prince has advanced two squares. When he reaches the last row it can promote to Direwolf.
@@ -118,7 +118,7 @@
Pawn
Griffon
-
+
This piece may appear in this game by promotion of a Ship. It moves one square diagonally and then, slides away of an indefinite number of squares vertically or horizontally.
@@ -127,7 +127,7 @@
Griffon
Rhinoceros
-
+
This piece may appear in this game by promotion of a Snake. It moves one square vertically or horizontally and then, slides away of an indefinite number of squares diagonally.
@@ -136,7 +136,7 @@
Rhinoceros
Direwolf
-
+
This piece may appear later on by promotion of a Pawn, a Prince or a Troll. It jumps on any square situated at 2 or 3 squares distance from where it stands.
@@ -145,7 +145,7 @@
Direwolf
Queen
-
+
Exactly as in usual Chess.
@@ -154,7 +154,7 @@
Queen
Bishop
-
+
Exactly as in usual Chess.
@@ -163,7 +163,7 @@
Bishop
Knight
-
+
Moves as in usual Chess. In addition, when a Knight reaches the last row it promotes to a Buffalo.
@@ -172,7 +172,7 @@
Knight
Rook
-
+
Exactly as in usual Chess.
@@ -181,7 +181,7 @@
Rook
Elephant
-
+
As in Shako. In this game, when the Elephant reaches the last row it promotes to a Lion.
@@ -190,7 +190,7 @@
Elephant
Machine
-
+
It is an orthogonal counterpart of the Elephant as it moves 1 or 2 cases orthogonally, jumping over the first case if it is occupied. Then, it combines the moves of old Dabbaba and Wazir found in ancient Muslim Chess variants. In this game, when the Machine reaches the last row it promotes to a Lion.
@@ -199,7 +199,7 @@
Machine
Lion
-
+
As in Metamachy, inspired (although with some simplification) by Chu Shogi, the most popular variant of the Japanese Chess. Here the Lion may move as a King (a single step move in any direction), or it may jump to a position two squares away, jumping in any orthogonal or diagonal direction, or alternatively jumping as a Knight in usual Chess. (Then this Lion has the same range but is more restricted than the Lion in Chu Shogi which can move two times in a turn).
@@ -209,7 +209,7 @@
Lion
Giraffe
-
+
a (3,2) jumper, it jumps to the opposite square of a 3x4 rectangle, like an extended Knight. No matter what intermediate squares contain. Note that it always changes the same color of its square. That piece is found in Alfonso X's Grant Acedrex (but its move has been rendered differently by 20th century historians). The same pattern, but with a non-jumping move, is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions.
@@ -218,16 +218,25 @@
Giraffe
Camel
-
+
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square. When a Camel reaches the last row it promotes to a Buffalo.
+
Hawk
+
+
+
+
It jumps horizontally, vertically or diagonally two or three squares, leaping over the intermediate squares if they are occupied.
+
+
+
+
Cannon
-
+
As in Xiangqi, in Shako and in Metamachy. (Also known as Pao by problemists).
@@ -236,7 +245,7 @@
Cannon
Bow
-
+
It is the diagonal counterpart of the Chinese Cannon. It moves like a Bishop and needs an intermediate piece between itself and its victim to capture it. The Bow jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. (Also known as Vao by problemists).
@@ -245,7 +254,7 @@
Bow
Buffalo
-
+
Jumps to the opposite case of a 3x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always changes the same color of its square. The same move is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions. When a Bull reaches the last row it promotes to a Buffalo.
@@ -254,7 +263,7 @@
Buffalo
Rhinoceros
-
+
Moves one square vertically or horizontally and then slides away an indefinite number of squares diagonally..
@@ -263,7 +272,7 @@
Rhinoceros
Marshall
-
+
It combines the move of Rook and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca and many others like Grand Chess or Gothic Chess. (under many other names: Champion, Guard, Empress, Concubine, Chancellor, etc. The later is sometimes preferred, however it is confusing since Capablanca used it once for R+N and once for B+N. It is an Elephant in Seirawan Chess).
@@ -272,7 +281,7 @@
Marshall
Cardinal
-
+
It combines the move of Bishop and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca, Modern and many others like Grand Chess or Gothic Chess. (under many other names: Centaur, Minister, Equerry, Janus, Archbishop, Princess, Chancellor, etc. It is a Hawk in Seirawan Chess).
@@ -281,7 +290,7 @@
Cardinal
Amazon
-
+
Strongest piece on the board, it combines the move of Queen and Knight. It was used in the Turkish-Indian Grand Chess (as a Giraffe).
@@ -290,7 +299,7 @@
Amazon
Centaur
-
+
it is another compound piece that moves as a Knight or a non-royal King.
@@ -299,25 +308,16 @@
Centaur
Admiral
-
+
it is another compound piece that moves as a Rook or a non-royal King. That means that it is a Rook that can also step one space diagonally.
-
Prince
-
-
-
-
a non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead.
-
-
-
-
Missionary
-
+
it is another compound piece that moves as a Bishop or a non-royal King. That means that it is a Bishop that can also step one space orthogonally.
@@ -327,7 +327,7 @@
Missionary
Soldier
-
+
it moves as a super-Pawn. It captures 1-square diagonally forward like a Pawn, but moves with no capture either 1-square forward or sideways (left or right). It can also step two empty squares forward from any position on the board..
@@ -345,7 +345,7 @@
Duchess
Bison
-
+
combines the leaps of the Knight (2,1), the Camel (3,1) and the Giraffe (3,2).
@@ -354,7 +354,7 @@
Bison
Archer
-
+
it is the diagonal counterpart of the Xiangqi's Cannon. It moves like a Bishop and needs an intermediate piece between itself and its victim to capture it. The Archer jumps the intermediate and takes the victim on its square.
@@ -367,7 +367,7 @@
Promotions table
promotes to
-
+
promotes to
@@ -378,7 +378,7 @@
Promotions table
promotes to
-
+
promotes to
@@ -388,7 +388,7 @@
Promotions table
promotes to
-
+
promotes to
diff --git a/src/games/chessbase/bigorra-thumb.png b/src/games/chessbase/res/rules/fantasticXIII/bigorra-thumb.png
similarity index 100%
rename from src/games/chessbase/bigorra-thumb.png
rename to src/games/chessbase/res/rules/fantasticXIII/bigorra-thumb.png
diff --git a/src/games/chessbase/fantasticXIII-credits.html b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-credits.html
similarity index 80%
rename from src/games/chessbase/fantasticXIII-credits.html
rename to src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-credits.html
index fe9264ed..4f6ba8c6 100644
--- a/src/games/chessbase/fantasticXIII-credits.html
+++ b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-credits.html
@@ -1,6 +1,6 @@
diff --git a/src/games/chessbase/fantasticXIII-description-fr.html b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-description-fr.html
similarity index 100%
rename from src/games/chessbase/fantasticXIII-description-fr.html
rename to src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-description-fr.html
diff --git a/src/games/chessbase/fantasticXIII-description.html b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-description.html
similarity index 100%
rename from src/games/chessbase/fantasticXIII-description.html
rename to src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-description.html
diff --git a/src/games/chessbase/fantasticXIII-rules-fr.html b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-rules-fr.html
similarity index 66%
rename from src/games/chessbase/fantasticXIII-rules-fr.html
rename to src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-rules-fr.html
index 98a95b8c..035e6075 100644
--- a/src/games/chessbase/fantasticXIII-rules-fr.html
+++ b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-rules-fr.html
@@ -28,12 +28,13 @@
Saute horizontallement, verticalement ou en diagonale de 2 ou 3 cases.
+
+
+
+
Loup garou
-
+
Cette pièce peut apparaître par la promotion d’un pion, d’un prince ou d’un Troll. Elle peut sauter à 2 ou 3 cases de distance.
@@ -141,4 +151,17 @@
Loup garou
+
Promotions
+
+
+
+
promu en
+
+
+
promu en
+
+
+
promu en
+
+
diff --git a/src/games/chessbase/fantasticXIII-rules.html b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-rules.html
similarity index 66%
rename from src/games/chessbase/fantasticXIII-rules.html
rename to src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-rules.html
index cd875d7c..97b46f42 100644
--- a/src/games/chessbase/fantasticXIII-rules.html
+++ b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-rules.html
@@ -28,15 +28,14 @@
Initial setup
The board has 13 x 13 squares.
-
-
+
Pieces
King
-
+
Moves as in usual Chess, except there is no castling.
@@ -45,7 +44,7 @@
King
Snake
-
+
Moves one square vertically and then, slides away of an indefinite number of squares diagonally. It can not jump and the unobstructed path must start with the vertical movement.
@@ -54,7 +53,7 @@
Snake
Ship
-
+
Moves one square diagonally and then, goes away of an indefinite number of cases vertically, never horizontally.
@@ -63,7 +62,7 @@
Ship
Mammoth
-
+
Steps horizontally, vertically or diagonally one or two squares, leaping over the intermediate square if it is occupied
@@ -72,7 +71,7 @@
Mammoth
Squirrel
-
+
Jumps at 2 squares
@@ -82,7 +81,7 @@
Squirrel
Cheetah
-
+
Jumps at 3 squares
@@ -91,7 +90,7 @@
Cheetah
Troll
-
+
Makes a 3-step orthogonal or diagonal jump, no matter what any intermediate square contains. In addition, it moves 1 step forward and captures 1 step diagonally forward (like a Pawn). This permits the Troll to reach any square on the board. It can promote to wolf only when it moves like a Pawn, never by jumping 3 squares
@@ -100,16 +99,16 @@
Troll
Prince
-
+
A non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to wolf.
-
+
Pawn
-
+
Moves straight forward one or two square from any position on the board, without capturing. It captures one square diagonally forward. As a consequence, the en-passant capture is possible every time an opposite Pawn or Prince has advanced two squares. When he reaches the last row it can promote to Direwolf.
@@ -118,7 +117,7 @@
Pawn
Griffon
-
+
This piece may appear in this game by promotion of a Ship. It moves one square diagonally and then, slides away of an indefinite number of squares vertically or horizontally.
@@ -127,22 +126,44 @@
Griffon
Rhinoceros
-
+
This piece may appear in this game by promotion of a Snake. It moves one square vertically or horizontally and then, slides away of an indefinite number of squares diagonally.
+
Hawk
+
+
+
+
It jumps horizontally, vertically or diagonally two or three squares, leaping over the intermediate squares if they are occupied.
+
+
+
+
Direwolf
-
+
This piece may appear later on by promotion of a Pawn, a Prince or a Troll. It jumps on any square situated at 2 or 3 squares distance from where it stands.
+
Promotions table
+
+
+
+
promotes to
+
+
+
promotes to
+
+
+
promotes to
+
+
diff --git a/src/games/chessbase/fantasticXIII-thumb.png b/src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-thumb.png
similarity index 100%
rename from src/games/chessbase/fantasticXIII-thumb.png
rename to src/games/chessbase/res/rules/fantasticXIII/fantasticXIII-thumb.png
diff --git a/src/games/chessbase/gigachess-credits.html b/src/games/chessbase/res/rules/gigachess/gigachess-credits.html
similarity index 100%
rename from src/games/chessbase/gigachess-credits.html
rename to src/games/chessbase/res/rules/gigachess/gigachess-credits.html
diff --git a/src/games/chessbase/gigachess-description.html b/src/games/chessbase/res/rules/gigachess/gigachess-description.html
similarity index 100%
rename from src/games/chessbase/gigachess-description.html
rename to src/games/chessbase/res/rules/gigachess/gigachess-description.html
diff --git a/src/games/chessbase/gigachess-rules.html b/src/games/chessbase/res/rules/gigachess/gigachess-rules.html
similarity index 93%
rename from src/games/chessbase/gigachess-rules.html
rename to src/games/chessbase/res/rules/gigachess/gigachess-rules.html
index 3f14716f..fdd08fff 100644
--- a/src/games/chessbase/gigachess-rules.html
+++ b/src/games/chessbase/res/rules/gigachess/gigachess-rules.html
@@ -31,13 +31,13 @@
6 Corporals on 3rd row and 14 Pawns on 3rd and 4th rows.
-
The white King is placed on the center of the second row on a black square, the black King being on a white square. The Queen is also placed on the center, beside the King. The Amazon is just behind the King. On the 1st row there is the "animal side" with Eagle, Lion, Buffalo from inside to outside, and the "knighted side" with Amazon, Marshall and Cardinal in this order. On 3rd row, Corporals occupy the six central columns.
+
The white King is placed on the center of the second row on a black square, the black King being on a white square. The Queen is also placed on the center, beside the King. The Amazon is just behind the King. On the 1st row there is the "animal side" with Griffon, Lion, Buffalo from inside to outside, and the "knighted side" with Amazon, Marshall and Cardinal in this order. On 3rd row, Corporals occupy the six central columns.
All short-range pieces (and the Ship as well) promote.
@@ -116,20 +116,20 @@
Lion
-
Eagle
+
Eagle/Griffon
-
+
As in Metamachy, moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex.
-
+
Ship
-
Originally invented for Tamerlane 2000, it moves one square diagonally and then, goes away of an indefinite number of cases vertically, never horizontally. It can move one square diagonally only. It can not jump and must begin its move with the diagonal step. The Ship is more limited than the Eagle (which can move horizontally). Nevertheless its move power is comparable to the Rook and the Bishop. When the Ship reaches the last row it promotes to an Eagle.
+
Originally invented for Tamerlane 2000, it moves one square diagonally and then, goes away of an indefinite number of cases vertically, never horizontally. It can move one square diagonally only. It can not jump and must begin its move with the diagonal step. The Ship is more limited than the Griffon (which can move horizontally). Nevertheless its move power is comparable to the Rook and the Bishop. When the Ship reaches the last row it promotes to an Griffon.
@@ -206,7 +206,7 @@
Promotions table
promotes to
-
+
promotes to
@@ -223,6 +223,6 @@
Promotions table
promotes to
-
+
diff --git a/src/games/chessbase/gigachess-thumb.png b/src/games/chessbase/res/rules/gigachess/gigachess-thumb.png
similarity index 100%
rename from src/games/chessbase/gigachess-thumb.png
rename to src/games/chessbase/res/rules/gigachess/gigachess-thumb.png
diff --git a/src/games/chessbase/gigachessII-credits.html b/src/games/chessbase/res/rules/gigachess/gigachessII-credits.html
similarity index 100%
rename from src/games/chessbase/gigachessII-credits.html
rename to src/games/chessbase/res/rules/gigachess/gigachessII-credits.html
diff --git a/src/games/chessbase/gigachessII-description.html b/src/games/chessbase/res/rules/gigachess/gigachessII-description.html
similarity index 100%
rename from src/games/chessbase/gigachessII-description.html
rename to src/games/chessbase/res/rules/gigachess/gigachessII-description.html
diff --git a/src/games/chessbase/res/rules/gigachess/gigachessII-rules.html b/src/games/chessbase/res/rules/gigachess/gigachessII-rules.html
new file mode 100644
index 00000000..5c073ba9
--- /dev/null
+++ b/src/games/chessbase/res/rules/gigachess/gigachessII-rules.html
@@ -0,0 +1,291 @@
+
+
+
+
Initial setup
+
+
The board is a 14 x 14 checkered squares with a white one at the right end of each player.
+
+
+
+
+The pieces are:
+
+The white King is placed on the center of the second row on a black square, the black King being on a white square. The Queen is also placed on the center, beside the King.
+
1 Lion, 1 Griffon 1 Missionary, 1 Admiral, and 2 Princes on 3rd row,
+
14 Pawns on 3rd and 4th rows.
+
+
+
+
The white King is placed on the center of the second row on a black square, the black King being on a white square. The Queen is also placed on the center, beside the King. The Amazon is just behind the King. On the 1st row there is the "animal side" with Griffon, Lion, Buffalo from inside to outside, and the "knighted side" with Amazon, Marshall and Cardinal in this order. On 3rd row, Corporals occupy the six central columns.
+
+
All short-range pieces (and the Ship as well) promote.
+
+
+
Pieces
+
+
King
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
Queen
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
Bishop
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
Knight
+
+
+
+
Moves as in usual Chess. In addition, when a Knight reaches the last row it promotes to a Buffalo.
+
+
+
+
+
Rook
+
+
+
+
Exactly as in usual Chess.
+
+
+
+
+
Elephant
+
+
+
+
As in Shako. In this game, when the Elephant reaches the last row it promotes to a Lion.
+
+
+
+
+
Machine
+
+
+
+
It is an orthogonal counterpart of the Elephant as it moves 1 or 2 cases orthogonally, jumping over the first case if it is occupied. Then, it combines the moves of old Dabbaba and Wazir found in ancient Muslim Chess variants. In this game, when the Machine reaches the last row it promotes to a Lion.
+
+
+
+
+
Lion
+
+
+
+
As in Metamachy, inspired (although with some simplification) by Chu Shogi, the most popular variant of the Japanese Chess. Here the Lion may move as a King (a single step move in any direction), or it may jump to a position two squares away, jumping in any orthogonal or diagonal direction, or alternatively jumping as a Knight in usual Chess. (Then this Lion has the same range but is more restricted than the Lion in Chu Shogi which can move two times in a turn).
+
+
+
+
+
Eagle/Griffon
+
+
+
+
As in Metamachy, moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex.
+
+
+
+
+
Giraffe
+
+
+
+
a (3,2) jumper, it jumps to the opposite square of a 3x4 rectangle, like an extended Knight. No matter what intermediate squares contain. Note that it always changes the same color of its square. That piece is found in Alfonso X's Grant Acedrex (but its move has been rendered differently by 20th century historians). The same pattern, but with a non-jumping move, is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions.
+
+
+
+
+
Camel
+
+
+
+
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square. When a Camel reaches the last row it promotes to a Buffalo.
+
+
+
+
+
Cannon
+
+
+
+
As in Xiangqi, in Shako and in Metamachy. (Also known as Pao by problemists).
+
+
+
+
+
Archer
+
+
+
+
It is the diagonal counterpart of the Chinese Cannon. It moves like a Bishop and needs an intermediate piece between itself and its victim to capture it. The Archer jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. (Also known as Vao by problemists).
+
+
+
+
+
Buffalo
+
+
+
+
Jumps to the opposite case of a 3x4 rectangle, like an extended Knight. No matter what intermediate cases contain.
+
+
+
+
+
Rhinoceros
+
+
+
+
Moves one square vertically or horizontally and then slides away an indefinite number of squares diagonally..
+
+
+
+
+
Marshall
+
+
+
+
It combines the move of Rook and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca and many others like Grand Chess or Gothic Chess. (under many other names: Champion, Guard, Empress, Concubine, Chancellor, etc. The later is sometimes preferred, however it is confusing since Capablanca used it once for R+N and once for B+N. It is an Elephant in Seirawan Chess).
+
+
+
+
+
Cardinal
+
+
+
+
It combines the move of Bishop and Knight. It can be found in many, many chess variants since Carrera, Bird, Capablanca, Modern and many others like Grand Chess or Gothic Chess. (under many other names: Centaur, Minister, Equerry, Janus, Archbishop, Princess, Chancellor, etc. It is a Hawk in Seirawan Chess).
+
+
+
+
+
Amazon
+
+
+
+
Strongest piece on the board, it combines the move of Queen and Knight. It was used in the Turkish-Indian Grand Chess (as a Giraffe).
+
+
+
+
+
Centaur
+
+
+
+
it is another compound piece that moves as a Knight or a non-royal King.
+
+
+
+
+
Admiral
+
+
+
+
it is another compound piece that moves as a Rook or a non-royal King. That means that it is a Rook that can also step one space diagonally.
+
+
+
+
+
Prince
+
+
+
+
a non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead.
+
+
+
+
+
Missionary
+
+
+
+
it is another compound piece that moves as a Bishop or a non-royal King. That means that it is a Bishop that can also step one space orthogonally.
+
+
+
+
+
Duchess
+
+
+
+
it moves as a limited Queen, one, two or three squares in any straight directions. When moving two or three squares, it may jump and it does not matter what any intermediate squares contain.
+
+
+
+
+
Sorceress
+
+
+
+
+
it moves like a Queen and needs an intermediate piece between itself and its victim to capture it. The Sorceress jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. Like the Queen is Bishop + Rook, the Sorceress is Cannon + Archer.
+
+
+
diff --git a/src/games/chessbase/res/rules/gigachess/gigachessII-thumb.png b/src/games/chessbase/res/rules/gigachess/gigachessII-thumb.png
new file mode 100644
index 00000000..9ec24ba5
Binary files /dev/null and b/src/games/chessbase/res/rules/gigachess/gigachessII-thumb.png differ
diff --git a/src/games/chessbase/glinski-credits.html b/src/games/chessbase/res/rules/glinski/glinski-credits.html
similarity index 100%
rename from src/games/chessbase/glinski-credits.html
rename to src/games/chessbase/res/rules/glinski/glinski-credits.html
diff --git a/src/games/chessbase/glinski-description.html b/src/games/chessbase/res/rules/glinski/glinski-description.html
similarity index 100%
rename from src/games/chessbase/glinski-description.html
rename to src/games/chessbase/res/rules/glinski/glinski-description.html
diff --git a/src/games/chessbase/glinski-rules.html b/src/games/chessbase/res/rules/glinski/glinski-rules.html
similarity index 100%
rename from src/games/chessbase/glinski-rules.html
rename to src/games/chessbase/res/rules/glinski/glinski-rules.html
diff --git a/src/games/chessbase/glinski-thumb.png b/src/games/chessbase/res/rules/glinski/glinski-thumb.png
similarity index 100%
rename from src/games/chessbase/glinski-thumb.png
rename to src/games/chessbase/res/rules/glinski/glinski-thumb.png
diff --git a/src/games/chessbase/gothic-credits.html b/src/games/chessbase/res/rules/gothic/gothic-credits.html
similarity index 100%
rename from src/games/chessbase/gothic-credits.html
rename to src/games/chessbase/res/rules/gothic/gothic-credits.html
diff --git a/src/games/chessbase/gothic-description.html b/src/games/chessbase/res/rules/gothic/gothic-description.html
similarity index 100%
rename from src/games/chessbase/gothic-description.html
rename to src/games/chessbase/res/rules/gothic/gothic-description.html
diff --git a/src/games/chessbase/gothic-rules.html b/src/games/chessbase/res/rules/gothic/gothic-rules.html
similarity index 100%
rename from src/games/chessbase/gothic-rules.html
rename to src/games/chessbase/res/rules/gothic/gothic-rules.html
diff --git a/src/games/chessbase/gothic-thumb.png b/src/games/chessbase/res/rules/gothic/gothic-thumb.png
similarity index 100%
rename from src/games/chessbase/gothic-thumb.png
rename to src/games/chessbase/res/rules/gothic/gothic-thumb.png
diff --git a/src/games/chessbase/res/rules/graphs/acedrex/leon.png b/src/games/chessbase/res/rules/graphs/acedrex/leon.png
new file mode 100644
index 00000000..08a374c4
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/acedrex/leon.png differ
diff --git a/src/games/chessbase/res/rules/graphs/bronze.png b/src/games/chessbase/res/rules/graphs/bronze.png
new file mode 100644
index 00000000..2ec67e78
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/bronze.png differ
diff --git a/src/games/chessbase/res/rules/graphs/champion.png b/src/games/chessbase/res/rules/graphs/champion.png
new file mode 100644
index 00000000..cdb4f4df
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/champion.png differ
diff --git a/src/games/chessbase/res/rules/graphs/gold.png b/src/games/chessbase/res/rules/graphs/gold.png
new file mode 100644
index 00000000..3793f80d
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/gold.png differ
diff --git a/src/games/chessbase/res/rules/graphs/hawk.png b/src/games/chessbase/res/rules/graphs/hawk.png
index ecbf5623..f0da3011 100644
Binary files a/src/games/chessbase/res/rules/graphs/hawk.png and b/src/games/chessbase/res/rules/graphs/hawk.png differ
diff --git a/src/games/chessbase/res/rules/graphs/kirin.png b/src/games/chessbase/res/rules/graphs/kirin.png
new file mode 100644
index 00000000..6b6734f6
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/kirin.png differ
diff --git a/src/games/chessbase/res/rules/graphs/phoenix.png b/src/games/chessbase/res/rules/graphs/phoenix.png
new file mode 100644
index 00000000..76bb6057
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/phoenix.png differ
diff --git a/src/games/chessbase/res/rules/graphs/prince2.png b/src/games/chessbase/res/rules/graphs/prince2.png
index f331c7fe..35d4025b 100644
Binary files a/src/games/chessbase/res/rules/graphs/prince2.png and b/src/games/chessbase/res/rules/graphs/prince2.png differ
diff --git a/src/games/chessbase/res/rules/graphs/samurai.png b/src/games/chessbase/res/rules/graphs/samurai.png
new file mode 100644
index 00000000..e085f3e8
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/samurai.png differ
diff --git a/src/games/chessbase/res/rules/graphs/silver.png b/src/games/chessbase/res/rules/graphs/silver.png
new file mode 100644
index 00000000..845da3f7
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/silver.png differ
diff --git a/src/games/chessbase/res/rules/graphs/snake.png b/src/games/chessbase/res/rules/graphs/snake.png
index 50604fa0..10c5147d 100644
Binary files a/src/games/chessbase/res/rules/graphs/snake.png and b/src/games/chessbase/res/rules/graphs/snake.png differ
diff --git a/src/games/chessbase/res/rules/graphs/wizard.png b/src/games/chessbase/res/rules/graphs/wizard.png
new file mode 100644
index 00000000..edcd99bc
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/wizard.png differ
diff --git a/src/games/chessbase/res/rules/graphs/zebra.png b/src/games/chessbase/res/rules/graphs/zebra.png
new file mode 100644
index 00000000..394a55fd
Binary files /dev/null and b/src/games/chessbase/res/rules/graphs/zebra.png differ
diff --git a/src/games/chessbase/wild-tamerlane-rules.html b/src/games/chessbase/res/rules/historical/acedrex-rules.html
similarity index 100%
rename from src/games/chessbase/wild-tamerlane-rules.html
rename to src/games/chessbase/res/rules/historical/acedrex-rules.html
diff --git a/src/games/chessbase/courier-credits.html b/src/games/chessbase/res/rules/historical/courier-credits.html
similarity index 100%
rename from src/games/chessbase/courier-credits.html
rename to src/games/chessbase/res/rules/historical/courier-credits.html
diff --git a/src/games/chessbase/courier-description.html b/src/games/chessbase/res/rules/historical/courier-description.html
similarity index 100%
rename from src/games/chessbase/courier-description.html
rename to src/games/chessbase/res/rules/historical/courier-description.html
diff --git a/src/games/chessbase/courier-rules.html b/src/games/chessbase/res/rules/historical/courier-rules.html
similarity index 100%
rename from src/games/chessbase/courier-rules.html
rename to src/games/chessbase/res/rules/historical/courier-rules.html
diff --git a/src/games/chessbase/courier-thumb.png b/src/games/chessbase/res/rules/historical/courier-thumb.png
similarity index 100%
rename from src/games/chessbase/courier-thumb.png
rename to src/games/chessbase/res/rules/historical/courier-thumb.png
diff --git a/src/games/chessbase/res/rules/historical/grant-acedrex-credits.html b/src/games/chessbase/res/rules/historical/grant-acedrex-credits.html
new file mode 100644
index 00000000..5cf1aa95
--- /dev/null
+++ b/src/games/chessbase/res/rules/historical/grant-acedrex-credits.html
@@ -0,0 +1,5 @@
+
Jocly implementation
+
+
Development: François Houdebert
+
Rules and descriptions: Jean-Louis Cazaux
+
diff --git a/src/games/chessbase/res/rules/historical/grant-acedrex-description.html b/src/games/chessbase/res/rules/historical/grant-acedrex-description.html
new file mode 100644
index 00000000..4bac23f1
--- /dev/null
+++ b/src/games/chessbase/res/rules/historical/grant-acedrex-description.html
@@ -0,0 +1,8 @@
+
+
+Grant Acedrex
+
+
+This large chess variant played on a 12x12 spaces board is found in a medieval Spanish codex (a form of ancient book) known as "Juegos diuersos de Acedrex, dados, y tablas con sus explicaciones, ordonados por mandado del rey don Alfonso el Sabio"(Various games of Chess, Dice and Tables with their explanations, ordered by request of King Alfonso the Wise). This king was Alfonso X (1221-1284), King of Castile, the central kingdom of Spain in Middle Ages. Author and poet, he compiled many books. This one was completed in 1283 in Seville, and is conserved at El Escorial near Madrid. It represents the most important existant testimony about games in the Middle Ages. Within 98 pages, it describes, details and comments on many rules and problems for several games. Grant Acedrex.
Steps 1 square in any direction. for its first move, the King can go 2 squares in any direction, leaping over the intermediate square if it is occupied (the text says as does the Alfferza. The Alfferza was the Fers, the Queen in medieval chess). That means it may leap to the 2nd square in straight line: straight ahead, diagonally or sideways, but not like a chess Knight. It may pass over an occupied square. The King cannot capture when jumping. The text does not specify if it may jump to escape a check or pass over a square controlled by the opponent. It is supposed that this was forbidden.
+
+
+
+
+
Aanca
+
+
+
+
moves 1 diagonal step followed by any number away on lines or columns. It may not jump over occupied squares. The Anqa is a mythical beast from the Arabian mythology which underlines the link between this game and the medieval Muslim chess variants. It was seen as a giant bird able to prey on elephants, and it was represented on the codex illustration as a sort of eagle.
+
+
+
+
+
Cocatriz
+
+
+
+
moves exactly as the modern chess Bishop. It must be noted that at the time of the codex, the 13th century, medieval chess had no modern Bishop but an "Alffil" instead which was moving as the Alfil of modern chess variants. The Cockatrice was a two-legged serpent-like monster with a rooster's head in medieval sources, though this piece is represented as a sort of crocodile in the codex illustration.
+
+
+
+
+
Zaraffa
+
+
+
+
it is the (3,2) leaper, meaning that it may go to the opposite square of a 4x3 rectangle, leaping over occupied squares if any. This move is also made by stepping 1 square orthogonally followed by 2 squares diagonally.
+
+
+
+
+
Roque
+
+
+
+
identical to the modern chess Rook, except there is no castling.
+
+
+
+
+
Unicornio
+
+
+
+
It leaps like a Knight, then proceeds diagonally away from the square it leaped to any number of vacant squares. This piece is depicted as a rhinoceros in the codex illustration, which is an indication of how exotic animals were poorly known in Europe during the Middle Ages and confused with mythical animals. .
+
+
+
+
+
Leon
+
+
+
+
it leaps 3 squares orthogonally or 2 squares orthogonally followed by 1 diagonal step. It may leap over occupied squares. Therefore it combines the moves of the Camel and the Threeleaper of modern chess variant nomenclature.
Saute de 3 cases orthogonallement ou de 2 cases orthogonallement suivi d’une en diagonale. Il combine le mouvement du chameau et du Threeleaper des variantes modernes.
+
+
+
+
+
+
diff --git a/src/games/chessbase/res/rules/historical/grant-acedrex-thumb.png b/src/games/chessbase/res/rules/historical/grant-acedrex-thumb.png
new file mode 100644
index 00000000..aec1cc46
Binary files /dev/null and b/src/games/chessbase/res/rules/historical/grant-acedrex-thumb.png differ
diff --git a/src/games/chessbase/res/rules/historical/grantacedrex-detail-r.png b/src/games/chessbase/res/rules/historical/grantacedrex-detail-r.png
new file mode 100644
index 00000000..35814ea7
Binary files /dev/null and b/src/games/chessbase/res/rules/historical/grantacedrex-detail-r.png differ
diff --git a/src/games/chessbase/res/rules/historical/grantacedrex.jpg b/src/games/chessbase/res/rules/historical/grantacedrex.jpg
new file mode 100644
index 00000000..6dce7f4d
Binary files /dev/null and b/src/games/chessbase/res/rules/historical/grantacedrex.jpg differ
diff --git a/src/games/chessbase/janus-credits.html b/src/games/chessbase/res/rules/janus/janus-credits.html
similarity index 100%
rename from src/games/chessbase/janus-credits.html
rename to src/games/chessbase/res/rules/janus/janus-credits.html
diff --git a/src/games/chessbase/janus-description.html b/src/games/chessbase/res/rules/janus/janus-description.html
similarity index 100%
rename from src/games/chessbase/janus-description.html
rename to src/games/chessbase/res/rules/janus/janus-description.html
diff --git a/src/games/chessbase/janus-rules.html b/src/games/chessbase/res/rules/janus/janus-rules.html
similarity index 100%
rename from src/games/chessbase/janus-rules.html
rename to src/games/chessbase/res/rules/janus/janus-rules.html
diff --git a/src/games/chessbase/janus-thumb.png b/src/games/chessbase/res/rules/janus/janus-thumb.png
similarity index 100%
rename from src/games/chessbase/janus-thumb.png
rename to src/games/chessbase/res/rules/janus/janus-thumb.png
diff --git a/src/games/chessbase/chancellor-credits.html b/src/games/chessbase/res/rules/knighted/chancellor-credits.html
similarity index 100%
rename from src/games/chessbase/chancellor-credits.html
rename to src/games/chessbase/res/rules/knighted/chancellor-credits.html
diff --git a/src/games/chessbase/chancellor-description.html b/src/games/chessbase/res/rules/knighted/chancellor-description.html
similarity index 100%
rename from src/games/chessbase/chancellor-description.html
rename to src/games/chessbase/res/rules/knighted/chancellor-description.html
diff --git a/src/games/chessbase/chancellor-rules.html b/src/games/chessbase/res/rules/knighted/chancellor-rules.html
similarity index 100%
rename from src/games/chessbase/chancellor-rules.html
rename to src/games/chessbase/res/rules/knighted/chancellor-rules.html
diff --git a/src/games/chessbase/chancellor-thumb.png b/src/games/chessbase/res/rules/knighted/chancellor-thumb.png
similarity index 100%
rename from src/games/chessbase/chancellor-thumb.png
rename to src/games/chessbase/res/rules/knighted/chancellor-thumb.png
diff --git a/src/games/chessbase/modern-credits.html b/src/games/chessbase/res/rules/knighted/modern-credits.html
similarity index 100%
rename from src/games/chessbase/modern-credits.html
rename to src/games/chessbase/res/rules/knighted/modern-credits.html
diff --git a/src/games/chessbase/modern-description.html b/src/games/chessbase/res/rules/knighted/modern-description.html
similarity index 100%
rename from src/games/chessbase/modern-description.html
rename to src/games/chessbase/res/rules/knighted/modern-description.html
diff --git a/src/games/chessbase/modern-rules.html b/src/games/chessbase/res/rules/knighted/modern-rules.html
similarity index 100%
rename from src/games/chessbase/modern-rules.html
rename to src/games/chessbase/res/rules/knighted/modern-rules.html
diff --git a/src/games/chessbase/modern-thumb.png b/src/games/chessbase/res/rules/knighted/modern-thumb.png
similarity index 100%
rename from src/games/chessbase/modern-thumb.png
rename to src/games/chessbase/res/rules/knighted/modern-thumb.png
diff --git a/src/games/chessbase/res/rules/makromachy/makromachy-credits.html b/src/games/chessbase/res/rules/makromachy/makromachy-credits.html
new file mode 100644
index 00000000..0b434962
--- /dev/null
+++ b/src/games/chessbase/res/rules/makromachy/makromachy-credits.html
@@ -0,0 +1,10 @@
+
Graphic design: Michel gutierrez (@_mig_), Jérôme Choain (@jcfrog) and H.G.Muller
+
+
diff --git a/src/games/chessbase/res/rules/makromachy/makromachy-description.html b/src/games/chessbase/res/rules/makromachy/makromachy-description.html
new file mode 100644
index 00000000..1c753e1c
--- /dev/null
+++ b/src/games/chessbase/res/rules/makromachy/makromachy-description.html
@@ -0,0 +1,21 @@
+
Makromachy is a huge chess variant (2x56 pieces on a 14x14 board)
+
+
+What distinguishes Makromachy from most other huge variants is that it is not just a mass of strong to super-strong pieces piled up on a board:
+special care is taken to speed up the game, by various methods.
+The piece density is larger than the usual 50%, bringing the armies closer together for earlier contact.
+
+
+A hand-full of pieces that can jump over arbitrary many others to capture or check put the Kings in jeopardy from the very beginning,
+so that checkmates don't have to wait until more than some 40 pieces are traded away.
+A super-strong piece capable of hit-and-run capture is subject to an anti-trading rule that will make it survive until very late in the game,
+so that the game doesn't easily get boring.
+
+
+What would normally be the slowest pieces, (such as Knights), have an extra 'airlift' non-capture move that can quickly bring them to where the action is,
+without making them significantly stronger.
+There also is a second rank of Pawnish pieces in the rear guard, to provide King shelter, and preserve promotion options.
+Care is taken that this cannot lead to unassailable double walls of Pawns, though.
+Not all pieces are super-strong (although many are stronger than a Queen);
+many of the unorthodox pieces are of Knight or Rook class, to provide good 2-vs-1 trading opportunities in any range of the value spectrum.
+
diff --git a/src/games/chessbase/res/rules/makromachy/makromachy-initial.jpg b/src/games/chessbase/res/rules/makromachy/makromachy-initial.jpg
new file mode 100644
index 00000000..573a6dba
Binary files /dev/null and b/src/games/chessbase/res/rules/makromachy/makromachy-initial.jpg differ
diff --git a/src/games/chessbase/res/rules/makromachy/makromachy-rules.html b/src/games/chessbase/res/rules/makromachy/makromachy-rules.html
new file mode 100644
index 00000000..704b8fe6
--- /dev/null
+++ b/src/games/chessbase/res/rules/makromachy/makromachy-rules.html
@@ -0,0 +1,365 @@
+
+
Differences from orthodox chess
+
Played on a 14x14 board, with 20 fairy piece involved next to the usual King, Bishop, Rook and Queen:
+
+
+
+
The Terror: moves and captures like Queen or a Knight. But can also leap directly to the second square in any diagonal or orthogonal direction. Finally it can perform hit-and-run capture on adjacent enemies, first capturing those, and then make one other King step to an empty square (but not the one it came from) in the same turn. Cannot capture a protected Terror.
+
+
+
+
The Eagle (aka Flying Queen or Great General): moves and captures like a Queen, but for capturing it can jump over arbitrary many pieces (friend or foe). The jumped-over pieces are not affected. It cannot jump over other flying pieces, (i.e. Eagle, Raven, Bat), or over an Archer, though. Cannot capture a protected Terror.
+
+
+
+
The Raven (aka Flying Rook or Rook General): moves and captures like a Rook, but for capturing it can jump over arbitrary many pieces (friend or foe). The jumped-over pieces are not affected. It cannot jump over other flying pieces, or over an Archer, though.
+
+
+
+
The Bat (aka Flying Bishop or Bishop General): moves and captures like a Bishop, but for capturing it can jump over arbitrary many pieces (friend or foe). The jumped-over pieces are not affected. It cannot jump over other flying pieces, or over an Archer, though.
+
+
+
The Archer: moves and captures one step orthogonally or jumps directly to the second square diagonally. Flying pieces cannot jump over it.
+
+
+
The Marshall: moves and captures like Knight or Rook.
+
+
+
The Archbishop: moves and captures like Knight or Bishop.
+
+
+
The Griffon: moves and captures by sliding along a trajectory that starts off by one diagonal step, and then continues outward like a Rook.
+
+
+
The Rhino: moves and captures by sliding along a trajectory that starts off by one orthogonal step, and then continues outward like a Bishop.
+
+
+
The Dragon King (aka Crowned Rook): moves and captures like King or Rook. Can castle with the King (see there).
+
+
+
The Dragon Horse (aka Crowned Bishop): moves and captures like King or Bishop.
+
+
+
The (enhanced) Champion: moves and captures to an adjacent orthogonal square, or by directly jumping to the second square diagonally or orthogonally. In addition has an 'airlift move', enabling it to slide like a Rook to where a piece (but not the board edge) in its path would block it.
+
+
+
The Camel (aka Long Knight): moves and captures by directly jumping to a square in the other corner of a rectangle of 2x4 squares.
+
+
+
The Zebra: moves and captures by directly jumping to a square in the other corner of a rectangle of 3x4 squares.
+
+
+
The (enhanced) Knight: moves and captures by directly jumping to a square in the other corner of a rectangle of 1x3 squares. In addition has an 'airlift move', enabling it to slide like a Bishop to where a piece standing at least four steps away (but not the board edge) in its path would block it.
+
+
+
The (enhanced) Elephant: moves and captures to a diagonally adjacent square or directly jumping to the second square diagonally. In addition has an 'airlift move', enabling it to slide like a Bishop to where a piece (but not the board edge) in its path would block it.
+
+
+
The Cannon: moves like a Rook, but can (and must) jump over one piece (friend or foe) in its path to capture.
+
+
+
The Diagonal Cannon (aka Vao): moves like a Bishop, but can (and must) jump over one piece (friend or foe) in its path to capture.
+
+
+
The Warrior: moves one or two squares straight ahead (non-jumping). Captures diagonally forward, or backward like a Knight. Its diagonal forward moves can capture Pawns or other Warriors en-passant on the squares these pass through.
+
+
+
The Pawn: moves and captures like an orthodox Pawn, but in its initial location it can also be pushed 3 steps forward, instead of two. Its diagonal forward moves can capture Warriors or other Pawns en-passant on the squares these pass through.
+
+
+
The King: moves and captures to any of the eight adjacent squares. A King that hasn't moved yet and is not in check can 'fast-castle' with a Dragon King (in the corner) that has not moved yet, by jumping directly to any empty square on the back rank in that direction, on which the Dragon King is moved to the square the King came from.
+
+
+
+
Inital setup
+
+
+
+
Each player starts with:
+
+
14 Pawns
+
6 Warriors
+
2 Diagonal Cannons
+
2 Cannons
+
2 (enhanced) Knights
+
2 Elephants
+
2 Camels
+
2 Zebras
+
2 Bishops
+
2 Rooks
+
2 Champions
+
2 Dragon Horses
+
2 Dragon Kings
+
2 Archers
+
2 Bats
+
2 Ravens
+
1 Rhino
+
1 Griffon
+
1 Archbishop
+
1 Marshall
+
1 Queen
+
1 Eagle
+
1 Terror
+
1 King
+
+
+
+
Castling: sort of. The King jumps directly to an empty square on the backrank, and the Dragon King in that direction takes its place.
+
Double move for Pawns (start): yes, even a triple move from their starting rank (the 4th!).
+
"En passant" capture: yes. To any of the squares passed through. Even Warriors can do this or fall victim to it.
+
Promotion: Pawns and Warriors promote on reaching the final rank,
+to any piece except King, Pawn, Warrior, Archer, Bat, Raven, Eagle or Terror.
+
Capture restrictions on Terrors:
+A Terror cannot be captured by a Terror or Eagle if pseudo-legal recapture would be possible on the immediately following half-move.
+
+
Threefold repetition is a draw, but it is not allowed to repeat a position through a move with an Eagle that delivers check even once.
Chess is a game played by two people on a chessboard, with sixteen pieces (of six types) for each player. Each type of piece moves in a distinct way.
+The goal of the game is to checkmate, i.e. to threaten the opponent's king with inevitable capture. In addition, there are several ways that a game can end in a draw.
+
+
Initial setup
+
+
+
Chess is played on a chessboard, a square board divided into 64 squares (eight-by-eight) of alternating color, which is similar to that used in
+draughts (checkers). No matter what the actual colors of the board, the lighter-colored squares are called "light" or "white", and the darker-colored squares
+are called "dark" or "black". Sixteen "white" and sixteen "black" pieces are placed on the board at the beginning of the game. The board is placed so that a
+white square is in each player's near-right corner.
+
+
Each player controls sixteen pieces:
+
+
+
+
Name
Number
White Symbols
Black Symbols
+
+
+
King
+
1
+
+
+
+
+
Queen
+
1
+
+
+
+
+
Rook
+
2
+
+
+
+
+
Bishop
+
2
+
+
+
+
+
Knight
+
2
+
+
+
+
+
Pawn
+
8
+
+
+
+
+
+
At the beginning of the game, the pieces are arranged as shown in the diagram. The second row from the player contains the eight pawns;
+the row nearest the player contains the remaining pieces. Popular phrases used to remember the setup, often heard in beginners' clubs,
+are "queen on her own color" and "white on right". The latter refers to setting up the board so that the square closest to each player's right
+is white.
+
+
Play of the game
+
+
The player controlling the white army is named "White"; the player controlling the black pieces is named "Black". White moves first,
+then players alternate moves. Making a move is required; it is not legal to skip a move, even when having to move is detrimental. Play
+continues until a king is checkmated, a player resigns, or a draw is declared, as explained below. In addition, if the game is being played
+under a time control players who exceed their time limit lose the game.
+
+
Movement
+
+
Basic moves
+
+
Each chess piece has its own method of movement. Moves are made to vacant squares except when capturing an opponent's piece.
+
+
With the exception of any movement of the knight and the occasional castling maneuver, pieces cannot jump over each other. When a piece is
+captured (or taken), the attacking piece replaces the enemy piece on its square (en passant being the only exception). The captured piece is
+thus removed from the game and may not be returned to play for the remainder of the game. The king can be put in check but cannot be
+captured (see below).
+
+
+
King
+
+
The king can move exactly one square horizontally, vertically, or diagonally. Only once per player, per game, is a king allowed to make a
+ special move known as castling (see below).
+
+
+
Rooks
+
+
The rook moves any number of vacant squares vertically or horizontally. It also is moved while castling.
+
+
+
Bishops
+
+
The bishop moves any number of vacant squares in any diagonal direction.
+
+
+
Queen
+
+
The queen can move any number of vacant squares diagonally, horizontally, or vertically.
+
+
+
Knights
+
+
The knight moves to the nearest square not on the same rank, file, or diagonal. In other words, the knight moves
+two squares horizontally then one square vertically, or one square horizontally then two squares vertically. Its move is not
+blocked by other pieces: it jumps to the new location.
+
+
+
Pawns
+
+
Pawns have the most complex rules of movement:
+
+
A pawn can move forward one square, if that square is unoccupied. If it has not yet moved, each pawn has the option of moving two squares
+forward provided both squares in front of the pawn are unoccupied. A pawn cannot move backwards.
+
Pawns are the only pieces that capture differently from how they move. They can capture an enemy piece on either of the two spaces adjacent to the space in front of them (i.e., the two squares diagonally in front of them) but cannot move to these spaces if they are vacant.
+
The pawn is also involved in the two special moves en passant and promotion.
+
+
+
Castling
+
+
Castling consists of moving the king two squares towards a rook, then placing the rook on the other side of the king, adjacent to it.
+Castling is only permissible if all of the following conditions hold:
+
+
+
The king and rook involved in castling must not have previously moved;
+
There must be no pieces between the king and the rook;
+
The king may not currently be in check, nor may the king pass through or end up in a square that is under attack by an enemy piece (though the
+rook is permitted to be under attack and to pass over an attacked square);
+
+
+
+
+
+
+
+
En passant
+
+
+
+
If player A's pawn moves forward two squares and player B has a pawn on its fifth rank on an adjacent file,
+B's pawn can capture A's pawn as if A's pawn had only moved one square. This capture can only be made on the immediately
+subsequent move. In this example, if the white pawn moves from a2 to a4, the black pawn on b4 can capture it en passant, ending up on a3.
+
+
Pawn promotion
+
+
If a pawn advances to its eighth rank, it is then promoted (converted) to a queen, rook, bishop, or knight of the same color, the choice
+being at the discretion of its player (a queen is usually chosen). The choice is not limited to previously captured pieces. Hence it is
+theoretically possible for a player to have up to nine queens or up to ten rooks, bishops, or knights if all of their pawns are promoted.
+If the desired piece is not available, the player should call the arbiter to provide the piece.
+
+
Check
+
+
+
+
A king is in check when it is under attack by one or more enemy pieces. A piece unable to move because it would place its own king in check
+(it is pinned against its own king) may still deliver check to the opposing player.
+
+
A player may not make any move which places or leaves his king in check. The possible ways to get out of check are:
+
+
+
+
Move the king to a square where it is not threatened.
+
Capture the threatening piece (possibly with the king).
+
Block the check by placing a piece between the king and the opponent's threatening piece.
+
+
+
End of the game
+
+
Checkmate
+
+
+
+
If a player's king is placed in check and there is no legal move that player can make to escape check, then the king is said to be checkmated,
+the game ends, and that player loses. Unlike other pieces, the king is never actually captured or removed from the board because checkmate ends
+the game.
+
+
The diagram shows a typical checkmate position. The white king is threatened by the black queen; every square to which the king could move is
+ also threatened; it cannot capture the queen, because it would then be threatened by the rook.
+
+
Draws
+
+
+
+
The game ends in a draw if any of these conditions occur:
+
+
The game is automatically a draw if the player to move is not in check but has no legal move. This situation is called a stalemate.
+ An example of such a position is shown in the diagram to the right.
+
The game is immediately drawn when there is no possibility of checkmate for either side with any series of legal moves. This draw is
+ often due to insufficient material, including the endgames
+
+
king against king;
+
king against king and bishop;
+
king against king and knight;
+
king and bishop against king and bishop, with both bishops on diagonals of the same color.
+
+
+
Both players agree to a draw after one of the players makes such an offer.
+
+
+
The player having the move may claim a draw by declaring that one of the following conditions exists, or by declaring an intention to
+make a move which will bring about one of these conditions:
+
+
+
Fifty-move rule: There has been no capture or pawn move in the last fifty moves by each player.
+
Threefold repetition: The same board position has occurred three times with the same player to move and all pieces having the same
+rights to move, including the right to castle or capture en passant.
+
+
+
If the claim is proven true, the game is drawn.
+
+
At one time, if a player was able to check the opposing king continually (perpetual check) and the player indicated their intention to do so,
+the game was drawn. This rule is no longer in effect; however, players will usually agree to a draw in such a situation, since either the rule on
+threefold repetition or the fifty-move rule will eventually be applicable.
diff --git a/src/games/chessbase/res/rules/makromachy/makromachy-thumb.png b/src/games/chessbase/res/rules/makromachy/makromachy-thumb.png
new file mode 100644
index 00000000..1c8bc02f
Binary files /dev/null and b/src/games/chessbase/res/rules/makromachy/makromachy-thumb.png differ
diff --git a/src/games/chessbase/mk-credits.html b/src/games/chessbase/res/rules/makruk/mk-credits.html
similarity index 100%
rename from src/games/chessbase/mk-credits.html
rename to src/games/chessbase/res/rules/makruk/mk-credits.html
diff --git a/src/games/chessbase/mk-description.html b/src/games/chessbase/res/rules/makruk/mk-description.html
similarity index 100%
rename from src/games/chessbase/mk-description.html
rename to src/games/chessbase/res/rules/makruk/mk-description.html
diff --git a/src/games/chessbase/mk-rules.html b/src/games/chessbase/res/rules/makruk/mk-rules.html
similarity index 100%
rename from src/games/chessbase/mk-rules.html
rename to src/games/chessbase/res/rules/makruk/mk-rules.html
diff --git a/src/games/chessbase/mk-thumb.png b/src/games/chessbase/res/rules/makruk/mk-thumb.png
similarity index 100%
rename from src/games/chessbase/mk-thumb.png
rename to src/games/chessbase/res/rules/makruk/mk-thumb.png
diff --git a/src/games/chessbase/mccooey-credits.html b/src/games/chessbase/res/rules/mccooey/mccooey-credits.html
similarity index 100%
rename from src/games/chessbase/mccooey-credits.html
rename to src/games/chessbase/res/rules/mccooey/mccooey-credits.html
diff --git a/src/games/chessbase/mccooey-description.html b/src/games/chessbase/res/rules/mccooey/mccooey-description.html
similarity index 100%
rename from src/games/chessbase/mccooey-description.html
rename to src/games/chessbase/res/rules/mccooey/mccooey-description.html
diff --git a/src/games/chessbase/mccooey-rules.html b/src/games/chessbase/res/rules/mccooey/mccooey-rules.html
similarity index 100%
rename from src/games/chessbase/mccooey-rules.html
rename to src/games/chessbase/res/rules/mccooey/mccooey-rules.html
diff --git a/src/games/chessbase/mccooey-thumb.png b/src/games/chessbase/res/rules/mccooey/mccooey-thumb.png
similarity index 100%
rename from src/games/chessbase/mccooey-thumb.png
rename to src/games/chessbase/res/rules/mccooey/mccooey-thumb.png
diff --git a/src/games/chessbase/metamachy-credits.html b/src/games/chessbase/res/rules/metamachy/metamachy-credits.html
similarity index 100%
rename from src/games/chessbase/metamachy-credits.html
rename to src/games/chessbase/res/rules/metamachy/metamachy-credits.html
diff --git a/src/games/chessbase/metamachy-description.html b/src/games/chessbase/res/rules/metamachy/metamachy-description.html
similarity index 100%
rename from src/games/chessbase/metamachy-description.html
rename to src/games/chessbase/res/rules/metamachy/metamachy-description.html
diff --git a/src/games/chessbase/metamachy-rules.html b/src/games/chessbase/res/rules/metamachy/metamachy-rules.html
similarity index 82%
rename from src/games/chessbase/metamachy-rules.html
rename to src/games/chessbase/res/rules/metamachy/metamachy-rules.html
index 1faa71f8..d988d97b 100644
--- a/src/games/chessbase/metamachy-rules.html
+++ b/src/games/chessbase/res/rules/metamachy/metamachy-rules.html
@@ -20,7 +20,7 @@
}
.mi-eagle
{
- background-image:url({GAME}/res/fairy/icons/w-eagle.png);
+ background-image:url({GAME}/res/fairy/icons/w-griffon.png);
}
.mi-lion
{
@@ -50,7 +50,7 @@
{
background-image:url({GAME}/res/fairy/icons/w-bishop.png);
}
- .mi-admiral
+ .mi-prince
{
background-image:url({GAME}/res/fairy/icons/w-admiral.png);
}
@@ -59,7 +59,7 @@
Presentation
It is a board game for 2 players using a 12x12 squares board.
-
There are 60 (5x12) pieces of 12 different types: King, Queen, Eagle, Lion, Prince, Bishop, Knight, Camel, Rook, Cannon, Elephant and 12 Pawns.
+
There are 60 (5x12) pieces of 12 different types: King, Queen, Griffon, Lion, Prince, Bishop, Knight, Camel, Rook, Cannon, Elephant and 12 Pawns.
There is a choice of 12 different starting setups. Black chooses the setup and White makes the first move.
@@ -73,13 +73,15 @@
Moves
Queen: slides to any square along the file, the rank or a diagonal on which it stands.
-Eagle: moves one square diagonally and then, slides away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement.
+Griffon: moves one square diagonally and then, slides away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement.
Lion: moves as a King (a single step move in any direction), or may jump to a position two squares away, jumping in any orthogonal or diagonal direction, or jumping as a Knight.
-Prince: a non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to one of the three major pieces: Queen, Lion or Eagle.
+
+Prince: a non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to one of the three major pieces: Queen, Lion or Eagle.
+
Bishop: slides to any square along a diagonal on which it stands. Note that it always stays on the same color of square.
@@ -100,16 +102,16 @@
Moves
Elephant: moves one or two squares diagonally. When an Elephant moves two squares, no matter what intermediate cases contain. Note that it always stays on the same color of square.
-Pawn: can move straight forward one or two square from any position on the board, without capturing. It captures one square diagonally forward. As a consequence, the en-passant capture is possible every time an opposite Pawn or Prince has advanced two squares. When he reaches the last row it can promote to one of the three major pieces: Queen, Lion or Eagle.
+Pawn: can move straight forward one or two square from any position on the board, without capturing. It captures one square diagonally forward. As a consequence, the en-passant capture is possible every time an opposite Pawn or Prince has advanced two squares. When he reaches the last row it can promote to one of the three major pieces: Queen, Lion or Griffon.
Setup rules
-
At the beginning all pieces but the Kings, Queens, Eagles and Lions are placed.
+
At the beginning all pieces but the Kings, Queens, Griffons and Lions are placed.
-
Then, Black freely decides where to place his King, Queen, Eagle and Lion on squares f1, g1, f2 and g2.
+
Then, Black freely decides where to place his King, Queen, Griffon and Lion on squares f1, g1, f2 and g2.
Then, White put his pieces symetrically in mirror (if Black King is on f1, White King goes on f12) and makes the first move.
@@ -121,7 +123,7 @@
Setup rules
The King can be on f1 or f2: 2 choices
Then, the Queen has a choice of 3 positions: beside the King, beneath the King or diagonal to the King.
-
Then, the Eagle has a choice of 2 remaining positions.
+
Then, the Griffon has a choice of 2 remaining positions.
Then, the left place is for the Lion. 2x3x2 = 12.
@@ -130,4 +132,5 @@
Setup rules
1 of the 12 possible starting positions
-
\ No newline at end of file
+
+
diff --git a/src/games/chessbase/metamachy-thumb.png b/src/games/chessbase/res/rules/metamachy/metamachy-thumb.png
similarity index 100%
rename from src/games/chessbase/metamachy-thumb.png
rename to src/games/chessbase/res/rules/metamachy/metamachy-thumb.png
diff --git a/src/games/chessbase/zanzibar-credits.html b/src/games/chessbase/res/rules/metamachy/zanzibar-credits.html
similarity index 100%
rename from src/games/chessbase/zanzibar-credits.html
rename to src/games/chessbase/res/rules/metamachy/zanzibar-credits.html
diff --git a/src/games/chessbase/zanzibar-description.html b/src/games/chessbase/res/rules/metamachy/zanzibar-description.html
similarity index 100%
rename from src/games/chessbase/zanzibar-description.html
rename to src/games/chessbase/res/rules/metamachy/zanzibar-description.html
diff --git a/src/games/chessbase/zanzibar-s-rules.html b/src/games/chessbase/res/rules/metamachy/zanzibar-s-rules.html
similarity index 84%
rename from src/games/chessbase/zanzibar-s-rules.html
rename to src/games/chessbase/res/rules/metamachy/zanzibar-s-rules.html
index 00b13aa0..88f62b4a 100644
--- a/src/games/chessbase/zanzibar-s-rules.html
+++ b/src/games/chessbase/res/rules/metamachy/zanzibar-s-rules.html
@@ -31,7 +31,7 @@
In Zanzibar-S there is no Duchess and no Sorceress.
Goal is checkmate the opposing King.
@@ -53,11 +53,11 @@
King
There is no castling in Zanzibar. At his first move, the King may jump to a free square at two squares' distance. For instance, from f2, it can jump to d1, d2, d3, d4, e4, f4, g4, h4, h3, h2 or h1). It does not matter if the square jumped over is occupied or not; however, the jump is forbidden if that intermediate square is threatened by an enemy piece. When jumping like a Knight, at least one of the two intermediate squares must be free of threat (e.g., if jumping from f2 to h3, either g2 or g3 must not be under attack). The King's jump is not permitted if the King is in check. This rule, which was once prevalent in medieval European chess, replaces castling. Identical to Metamachy.
-
+
Queen
-
+
Exactly as in usual Chess.
@@ -66,7 +66,7 @@
Queen
Bishop
-
+
Exactly as in usual Chess.
@@ -75,7 +75,7 @@
Bishop
Knight
-
+
Moves as in usual Chess. In addition, when a Knight reaches the last row it promotes to a Buffalo.
@@ -84,7 +84,7 @@
Knight
Rook
-
+
Exactly as in usual Chess.
@@ -93,7 +93,7 @@
Rook
Elephant
-
+
As in Shako. In this game, when the Elephant reaches the last row it promotes to a Lion.
@@ -102,7 +102,7 @@
Elephant
Machine
-
+
It is an orthogonal counterpart of the Elephant as it moves 1 or 2 cases orthogonally, jumping over the first case if it is occupied. Then, it combines the moves of old Dabbaba and Wazir found in ancient Muslim Chess variants. In this game, when the Machine reaches the last row it promotes to a Lion.
@@ -111,25 +111,25 @@
Machine
Lion
-
+
As in Metamachy, inspired (although with some simplification) by Chu Shogi, the most popular variant of the Japanese Chess. Here the Lion may move as a King (a single step move in any direction), or it may jump to a position two squares away, jumping in any orthogonal or diagonal direction, or alternatively jumping as a Knight in usual Chess. (Then this Lion has the same range but is more restricted than the Lion in Chu Shogi which can move two times in a turn).
-
Eagle
+
Eagle/Griffon
-
+
As in Metamachy, moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex.
-
+
Giraffe
-
+
a (3,2) jumper, it jumps to the opposite square of a 3x4 rectangle, like an extended Knight. No matter what intermediate squares contain. Note that it always changes the same color of its square. That piece is found in Alfonso X's Grant Acedrex (but its move has been rendered differently by 20th century historians). The same pattern, but with a non-jumping move, is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions.
@@ -138,7 +138,7 @@
Giraffe
Camel
-
+
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square. When a Camel reaches the last row it promotes to a Buffalo.
@@ -147,7 +147,7 @@
Camel
Prince
-
+
a non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead.
@@ -156,7 +156,7 @@
Prince
Cannon
-
+
As in Xiangqi, in Shako and in Metamachy. (Also known as Pao by problemists).
@@ -165,7 +165,7 @@
Cannon
Bow
-
+
It is the diagonal counterpart of the Chinese Cannon. It moves like a Bishop and needs an intermediate piece between itself and its victim to capture it. The Bow jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. (Also known as Vao by problemists).
@@ -174,7 +174,7 @@
Bow
Bull
-
+
Jumps to the opposite case of a 3x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always changes the same color of its square. The same move is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions. When a Bull reaches the last row it promotes to a Buffalo.
@@ -183,7 +183,7 @@
Bull
Rhinoceros
-
+
Moves one square vertically or horizontally and then slides away an indefinite number of squares diagonally..
@@ -193,10 +193,10 @@
Rhinoceros
Setup rules
-
At the beginning all pieces but the Kings, Queens, Eagles, Lions, Rhinoceros and buffalo are placed.
+
At the beginning all pieces but the Kings, Queens, Griffons, Lions, Rhinoceros and buffalo are placed.
-
Then, Black freely decides where to place his King, Queen, Eagle and Lion on squares f1, g1, f2 and g2.
+
Then, Black freely decides where to place his King, Queen, Griffon and Lion on squares f1, g1, f2 and g2.
Then, White put his pieces symetrically in mirror (if Black King is on f1, White King goes on f12) and makes the first move.
@@ -208,7 +208,7 @@
Setup rules
The King can be on f1 or f2: 2 choices
Then, the Queen has a choice of 3 positions: beside the King, beneath the King or diagonal to the King.
-
Then, the Eagle has a choice of 2 remaining positions.
+
Then, the Griffon has a choice of 2 remaining positions.
Then, the left place is for the Lion.
Then, the Rhinoceros has a choice of 2 remaining positions.
Then, the left place is for the Buffalo. 2x3x2x2 = 24.
+
+
+
diff --git a/src/games/chessbase/zanzibar-s-thumb.png b/src/games/chessbase/res/rules/metamachy/zanzibar-s-thumb.png
similarity index 100%
rename from src/games/chessbase/zanzibar-s-thumb.png
rename to src/games/chessbase/res/rules/metamachy/zanzibar-s-thumb.png
diff --git a/src/games/chessbase/attack-credits.html b/src/games/chessbase/res/rules/mini/attack-credits.html
similarity index 100%
rename from src/games/chessbase/attack-credits.html
rename to src/games/chessbase/res/rules/mini/attack-credits.html
diff --git a/src/games/chessbase/attack-description.html b/src/games/chessbase/res/rules/mini/attack-description.html
similarity index 100%
rename from src/games/chessbase/attack-description.html
rename to src/games/chessbase/res/rules/mini/attack-description.html
diff --git a/src/games/chessbase/attack-rules.html b/src/games/chessbase/res/rules/mini/attack-rules.html
similarity index 100%
rename from src/games/chessbase/attack-rules.html
rename to src/games/chessbase/res/rules/mini/attack-rules.html
diff --git a/src/games/chessbase/attack-thumb.png b/src/games/chessbase/res/rules/mini/attack-thumb.png
similarity index 100%
rename from src/games/chessbase/attack-thumb.png
rename to src/games/chessbase/res/rules/mini/attack-thumb.png
diff --git a/src/games/chessbase/baby-credits.html b/src/games/chessbase/res/rules/mini/baby-credits.html
similarity index 100%
rename from src/games/chessbase/baby-credits.html
rename to src/games/chessbase/res/rules/mini/baby-credits.html
diff --git a/src/games/chessbase/baby-description.html b/src/games/chessbase/res/rules/mini/baby-description.html
similarity index 100%
rename from src/games/chessbase/baby-description.html
rename to src/games/chessbase/res/rules/mini/baby-description.html
diff --git a/src/games/chessbase/baby-rules.html b/src/games/chessbase/res/rules/mini/baby-rules.html
similarity index 100%
rename from src/games/chessbase/baby-rules.html
rename to src/games/chessbase/res/rules/mini/baby-rules.html
diff --git a/src/games/chessbase/baby-thumb.png b/src/games/chessbase/res/rules/mini/baby-thumb.png
similarity index 100%
rename from src/games/chessbase/baby-thumb.png
rename to src/games/chessbase/res/rules/mini/baby-thumb.png
diff --git a/src/games/chessbase/gardner-credits.html b/src/games/chessbase/res/rules/mini/gardner-credits.html
similarity index 100%
rename from src/games/chessbase/gardner-credits.html
rename to src/games/chessbase/res/rules/mini/gardner-credits.html
diff --git a/src/games/chessbase/gardner-description.html b/src/games/chessbase/res/rules/mini/gardner-description.html
similarity index 100%
rename from src/games/chessbase/gardner-description.html
rename to src/games/chessbase/res/rules/mini/gardner-description.html
diff --git a/src/games/chessbase/gardner-rules.html b/src/games/chessbase/res/rules/mini/gardner-rules.html
similarity index 100%
rename from src/games/chessbase/gardner-rules.html
rename to src/games/chessbase/res/rules/mini/gardner-rules.html
diff --git a/src/games/chessbase/gardner-thumb.png b/src/games/chessbase/res/rules/mini/gardner-thumb.png
similarity index 100%
rename from src/games/chessbase/gardner-thumb.png
rename to src/games/chessbase/res/rules/mini/gardner-thumb.png
diff --git a/src/games/chessbase/los-alamos-credits.html b/src/games/chessbase/res/rules/mini/los-alamos-credits.html
similarity index 100%
rename from src/games/chessbase/los-alamos-credits.html
rename to src/games/chessbase/res/rules/mini/los-alamos-credits.html
diff --git a/src/games/chessbase/los-alamos-description.html b/src/games/chessbase/res/rules/mini/los-alamos-description.html
similarity index 100%
rename from src/games/chessbase/los-alamos-description.html
rename to src/games/chessbase/res/rules/mini/los-alamos-description.html
diff --git a/src/games/chessbase/los-alamos-rules.html b/src/games/chessbase/res/rules/mini/los-alamos-rules.html
similarity index 100%
rename from src/games/chessbase/los-alamos-rules.html
rename to src/games/chessbase/res/rules/mini/los-alamos-rules.html
diff --git a/src/games/chessbase/los-alamos-thumb.png b/src/games/chessbase/res/rules/mini/los-alamos-thumb.png
similarity index 100%
rename from src/games/chessbase/los-alamos-thumb.png
rename to src/games/chessbase/res/rules/mini/los-alamos-thumb.png
diff --git a/src/games/chessbase/malett-credits.html b/src/games/chessbase/res/rules/mini/malett-credits.html
similarity index 100%
rename from src/games/chessbase/malett-credits.html
rename to src/games/chessbase/res/rules/mini/malett-credits.html
diff --git a/src/games/chessbase/malett-description.html b/src/games/chessbase/res/rules/mini/malett-description.html
similarity index 100%
rename from src/games/chessbase/malett-description.html
rename to src/games/chessbase/res/rules/mini/malett-description.html
diff --git a/src/games/chessbase/malett-rules.html b/src/games/chessbase/res/rules/mini/malett-rules.html
similarity index 100%
rename from src/games/chessbase/malett-rules.html
rename to src/games/chessbase/res/rules/mini/malett-rules.html
diff --git a/src/games/chessbase/malett-thumb.png b/src/games/chessbase/res/rules/mini/malett-thumb.png
similarity index 100%
rename from src/games/chessbase/malett-thumb.png
rename to src/games/chessbase/res/rules/mini/malett-thumb.png
diff --git a/src/games/chessbase/micro4x5-credits.html b/src/games/chessbase/res/rules/mini/micro4x5-credits.html
similarity index 100%
rename from src/games/chessbase/micro4x5-credits.html
rename to src/games/chessbase/res/rules/mini/micro4x5-credits.html
diff --git a/src/games/chessbase/micro4x5-description.html b/src/games/chessbase/res/rules/mini/micro4x5-description.html
similarity index 100%
rename from src/games/chessbase/micro4x5-description.html
rename to src/games/chessbase/res/rules/mini/micro4x5-description.html
diff --git a/src/games/chessbase/micro4x5-rules.html b/src/games/chessbase/res/rules/mini/micro4x5-rules.html
similarity index 100%
rename from src/games/chessbase/micro4x5-rules.html
rename to src/games/chessbase/res/rules/mini/micro4x5-rules.html
diff --git a/src/games/chessbase/micro4x5-thumb.png b/src/games/chessbase/res/rules/mini/micro4x5-thumb.png
similarity index 100%
rename from src/games/chessbase/micro4x5-thumb.png
rename to src/games/chessbase/res/rules/mini/micro4x5-thumb.png
diff --git a/src/games/chessbase/mini4x4-credits.html b/src/games/chessbase/res/rules/mini/mini4x4-credits.html
similarity index 100%
rename from src/games/chessbase/mini4x4-credits.html
rename to src/games/chessbase/res/rules/mini/mini4x4-credits.html
diff --git a/src/games/chessbase/mini4x4-description.html b/src/games/chessbase/res/rules/mini/mini4x4-description.html
similarity index 100%
rename from src/games/chessbase/mini4x4-description.html
rename to src/games/chessbase/res/rules/mini/mini4x4-description.html
diff --git a/src/games/chessbase/mini4x4-rules.html b/src/games/chessbase/res/rules/mini/mini4x4-rules.html
similarity index 100%
rename from src/games/chessbase/mini4x4-rules.html
rename to src/games/chessbase/res/rules/mini/mini4x4-rules.html
diff --git a/src/games/chessbase/mini4x4-thumb.png b/src/games/chessbase/res/rules/mini/mini4x4-thumb.png
similarity index 100%
rename from src/games/chessbase/mini4x4-thumb.png
rename to src/games/chessbase/res/rules/mini/mini4x4-thumb.png
diff --git a/src/games/chessbase/mini4x5-credits.html b/src/games/chessbase/res/rules/mini/mini4x5-credits.html
similarity index 100%
rename from src/games/chessbase/mini4x5-credits.html
rename to src/games/chessbase/res/rules/mini/mini4x5-credits.html
diff --git a/src/games/chessbase/mini4x5-description.html b/src/games/chessbase/res/rules/mini/mini4x5-description.html
similarity index 100%
rename from src/games/chessbase/mini4x5-description.html
rename to src/games/chessbase/res/rules/mini/mini4x5-description.html
diff --git a/src/games/chessbase/mini4x5-rules.html b/src/games/chessbase/res/rules/mini/mini4x5-rules.html
similarity index 100%
rename from src/games/chessbase/mini4x5-rules.html
rename to src/games/chessbase/res/rules/mini/mini4x5-rules.html
diff --git a/src/games/chessbase/mini4x5-thumb.png b/src/games/chessbase/res/rules/mini/mini4x5-thumb.png
similarity index 100%
rename from src/games/chessbase/mini4x5-thumb.png
rename to src/games/chessbase/res/rules/mini/mini4x5-thumb.png
diff --git a/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-credits.html b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-credits.html
new file mode 100644
index 00000000..a81c36e0
--- /dev/null
+++ b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-credits.html
@@ -0,0 +1,10 @@
+
Graphic design: Michel gutierrez (@_mig_), Jérôme Choain (@jcfrog) and H.G.Muller
+
+
diff --git a/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-description.html b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-description.html
new file mode 100644
index 00000000..6ac96f05
--- /dev/null
+++ b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-description.html
@@ -0,0 +1,17 @@
+
Minjiku Shogi is a very wild Shogi variant, that despite its large size (2x32 pieces on 10x10) can be quickly decided
+
+
+Minjiku Shogi is basically a miniaturized version of Tenjiku Shogi (which has more than double the number of pieces);
+the participating pieces are mostly novel, 'caricatures' of the Tenjiku pieces, adapted to the smaller board.
+
+
+A hand-full of pieces that can jump over arbitrary many others to capture or check put the Kings in jeopardy from the very beginning,
+so that checkmates don't have to wait until more than some 40 pieces are traded away.
+Indeed white can already threaten mate in 1 on its first move!
+A super-strong piece can burn its neighbors, and capture 5 pieces at once this way.
+
+
+As is typical for Shogi, most pieces can promote (once!) to a predetermined stronger piece.
+So apart from the 16 piece types in the inital setup,
+many appear also in a versions that cannot be further promoted, and 4 entirely new types can be obtained by promotion.
+
diff --git a/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-initial.jpg b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-initial.jpg
new file mode 100644
index 00000000..2f3d3cfd
Binary files /dev/null and b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-initial.jpg differ
diff --git a/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-rules.html b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-rules.html
new file mode 100644
index 00000000..50d16701
--- /dev/null
+++ b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-rules.html
@@ -0,0 +1,402 @@
+
+
Differences from orthodox chess
+
Since this is a Shogi variant the differences with orthodox chess are numerous.
+The most striking differences between chess and shogi are the Pawn move, and the fact that pieces other than Pawns can promote too, even before they reach last rank.
+
+Minjiku Shogi is played on a 10x10 board, with 4 additional squares that disappear when no longer occupied.
+Unlike in modern shogi, captured pieces cannot be dropped, but remain out of play forever.
+Of the orthodox shogi pieces only the King, Pawn, Rook and Bishop participate, but Queen, Kirin and Phoenix are known from many of the larger shogi variants,
+and the jumping sliders are known from the historic shogi variant variant tenjiku shogi.
+Most other piece are novelties, especially conceived for this game.
+Even most of the orthodox Shogi pieces have different promotions than usual.
+
+
Move types
+
+In Minjiku Shogi there are several types of special moves.
+For one, there are 'flying' pieces that can jump over arbitrary many other pieces to capture.
+But they cannot always jump over each other.
+Then there is an 'area move', which consists of one or two King steps, not necessarily in the same direction.
+The second step can only be made if the first went to an empty square.
+Some pieces have the ability to capture an adjacent piece without moving themselves:
+the adjacent piece is simply taken off the board ('rifle capture').
+Finally there is a capture mode called 'burning', which removes every enemy diagonally adjacent to the square where the move ends.
+
+
The pieces
+
+
+
The Fire Dragon: moves and captures like Queen, and has an 'area move' (see below for Lion).
+ But it also automatically captures ('burns') all enemies diagonally adjacent to a square it ends its move on.
+
+
+
+
The Jumping General (aka Great General): moves and captures like a Queen, but for capturing it can jump over arbitrary many pieces (friend or foe).
+ The jumped-over pieces are not affected. It cannot jump over another Jumping General or King, though.
+
+
+
+
The Area Jumper: moves and captures like a Bishop, but for capturing it can jump over arbitrary many pieces (friend or foe).
+ The jumped-over pieces are not affected. It cannot jump over a Jumping General, King or other Area Jumper, though.
+ In addition it has an 'area move' (see below for Lion).
+
+
+
+
The Orthogonal Jumper (aka Rook General): moves and captures like a Rook, but for capturing it can jump over arbitrary many pieces (friend or foe).
+ The jumped-over pieces are not affected. It cannot jump over a Jumping General, Area Jumper, Diagonal Jumper, King or other Orthogonal Jumper, though.
+
+
+
+
The Lion: moves or captures as a King, but if the square thus reached is empty it can optionally move on or capture to a square adjacent to that ('area move').
+ It cannot return to where it came from, though.
+
+
+
+
The Samurai: moves and captures like an orthodox Knight, and can capture adjacent enemies in all 8 directions without moving.
+
+
+
+
The Ninja: moves and captures sideways like a Rook, but skips the adjacent square (whether empty or occupied) when doing so.
+ Can also move or capture to diagonally adjacent squares, or capture orthogonally adjacent enemies without moving.
+
+
+
+
The Queen: moves and captures like an orthodox Queen.
+
+
+
+
The Diagonal Jumper (aka Bishop General): moves and captures like a Bishop, but for capturing it can jump over arbitrary many pieces (friend or foe).
+ The jumped-over pieces are not affected. It cannot jump over a Jumping General, Area Jumper, Orthogonal Jumper, King or other Diagonal Jumper, though.
+
+
+
+
The Cobra: moves and captures like a Rook, and can capture diagonally adjacent enemies without moving.
+
+
+
+
The Viper: moves and captures like a Bishop, and can capture orthogonally adjacent enemies without moving.
+
+
+
+
The Rook: moves and captures like an orthodox Rook.
+
+
+
+
The Bishop: moves and captures like an orthodox Bishop.
+
+
+
+
The Lateral Mover: moves and captures by sliding sideways like a Rook, or to orthogonally adjacent squares.
+ If it has not moved yet it can also move and capture by sliding 2 squares forward (non-jumping!).
+
+
+
+
The Phoenix: moves and captures to orthogonally adjacent squares, or by jumping to the second square diagonally.
+
+
+
+
The Kirin: moves and captures to diagonally adjacent squares, or by jumping to the second square orthogonally.
+
+
+
+
The Minister: moves and captures like an orthodox King. The square the Minister starts on disappears as soon as it gets evacuated.
+
+
+
+
The Gold General: moves and captures to adjacent squares in any orthogonal or the forward diagonal direction.
+
+
+
+
The Silver General: moves and captures to adjacent squares in any diagonal or the forward orthogonal direction.
+
+
+
+
The Pawn: moves and captures to the square directly in front of it.
+
+
+
+
The King: moves and captures to any of the eight adjacent squares. The square the King starts on disappears as soon as it gets evacuated.
+
+
+
+
Inital setup
+
+
+
+
Each player starts with:
+
+
10 Pawns, which can promote to Gold General
+
2 Silver Generals, which can promote to Bishop
+
2 Gold Generals, which can promote to Rook
+
2 Lateral Movers, which can promote to Ninja
+
2 Bishops, which can promote to Viper
+
2 Rooks, which can promote to Cobra
+
2 Diagonal Jumpers, which can promote to Lion
+
1 Minister, which can promote to Orthogonal Jumper
+
1 Kirin, which can promote to Samurai
+
1 Phoenix, which can promote to Queen
+
1 Queen, which can promote to Fire Dragon
+
1 Viper, which can promote to Area Jumper
+
1 Cobra, which can promote to Jumping General
+
1 Area Jumper
+
1 Jumping General
+
1 Fire Dragon
+
1 King
+
+
+
+
Castling: no.
+
Double move for Pawns (start): no.
+
"En passant" capture: no.
+
Piece drops: no.
+
Promotion: most pieces can promote, to a dedicated promoted type, when they enter the promotion zone consisting of the last three ranks, or capture a piece in it.
+This is optional.
+Once promoted the pieces cannot promote again, even if an identically moving piece in the initial setup could.
Chess is a game played by two people on a chessboard, with sixteen pieces (of six types) for each player. Each type of piece moves in a distinct way.
+The goal of the game is to checkmate, i.e. to threaten the opponent's king with inevitable capture. In addition, there are several ways that a game can end in a draw.
+
+
Initial setup
+
+
+
Chess is played on a chessboard, a square board divided into 64 squares (eight-by-eight) of alternating color, which is similar to that used in
+draughts (checkers). No matter what the actual colors of the board, the lighter-colored squares are called "light" or "white", and the darker-colored squares
+are called "dark" or "black". Sixteen "white" and sixteen "black" pieces are placed on the board at the beginning of the game. The board is placed so that a
+white square is in each player's near-right corner.
+
+
Each player controls sixteen pieces:
+
+
+
+
Name
Number
White Symbols
Black Symbols
+
+
+
King
+
1
+
+
+
+
+
Queen
+
1
+
+
+
+
+
Rook
+
2
+
+
+
+
+
Bishop
+
2
+
+
+
+
+
Knight
+
2
+
+
+
+
+
Pawn
+
8
+
+
+
+
+
+
At the beginning of the game, the pieces are arranged as shown in the diagram. The second row from the player contains the eight pawns;
+the row nearest the player contains the remaining pieces. Popular phrases used to remember the setup, often heard in beginners' clubs,
+are "queen on her own color" and "white on right". The latter refers to setting up the board so that the square closest to each player's right
+is white.
+
+
Play of the game
+
+
The player controlling the white army is named "White"; the player controlling the black pieces is named "Black". White moves first,
+then players alternate moves. Making a move is required; it is not legal to skip a move, even when having to move is detrimental. Play
+continues until a king is checkmated, a player resigns, or a draw is declared, as explained below. In addition, if the game is being played
+under a time control players who exceed their time limit lose the game.
+
+
Movement
+
+
Basic moves
+
+
Each chess piece has its own method of movement. Moves are made to vacant squares except when capturing an opponent's piece.
+
+
With the exception of any movement of the knight and the occasional castling maneuver, pieces cannot jump over each other. When a piece is
+captured (or taken), the attacking piece replaces the enemy piece on its square (en passant being the only exception). The captured piece is
+thus removed from the game and may not be returned to play for the remainder of the game. The king can be put in check but cannot be
+captured (see below).
+
+
+
King
+
+
The king can move exactly one square horizontally, vertically, or diagonally. Only once per player, per game, is a king allowed to make a
+ special move known as castling (see below).
+
+
+
Rooks
+
+
The rook moves any number of vacant squares vertically or horizontally. It also is moved while castling.
+
+
+
Bishops
+
+
The bishop moves any number of vacant squares in any diagonal direction.
+
+
+
Queen
+
+
The queen can move any number of vacant squares diagonally, horizontally, or vertically.
+
+
+
Knights
+
+
The knight moves to the nearest square not on the same rank, file, or diagonal. In other words, the knight moves
+two squares horizontally then one square vertically, or one square horizontally then two squares vertically. Its move is not
+blocked by other pieces: it jumps to the new location.
+
+
+
Pawns
+
+
Pawns have the most complex rules of movement:
+
+
A pawn can move forward one square, if that square is unoccupied. If it has not yet moved, each pawn has the option of moving two squares
+forward provided both squares in front of the pawn are unoccupied. A pawn cannot move backwards.
+
Pawns are the only pieces that capture differently from how they move. They can capture an enemy piece on either of the two spaces adjacent to the space in front of them (i.e., the two squares diagonally in front of them) but cannot move to these spaces if they are vacant.
+
The pawn is also involved in the two special moves en passant and promotion.
+
+
+
Castling
+
+
Castling consists of moving the king two squares towards a rook, then placing the rook on the other side of the king, adjacent to it.
+Castling is only permissible if all of the following conditions hold:
+
+
+
The king and rook involved in castling must not have previously moved;
+
There must be no pieces between the king and the rook;
+
The king may not currently be in check, nor may the king pass through or end up in a square that is under attack by an enemy piece (though the
+rook is permitted to be under attack and to pass over an attacked square);
+
+
+
+
+
+
+
+
En passant
+
+
+
+
If player A's pawn moves forward two squares and player B has a pawn on its fifth rank on an adjacent file,
+B's pawn can capture A's pawn as if A's pawn had only moved one square. This capture can only be made on the immediately
+subsequent move. In this example, if the white pawn moves from a2 to a4, the black pawn on b4 can capture it en passant, ending up on a3.
+
+
Pawn promotion
+
+
If a pawn advances to its eighth rank, it is then promoted (converted) to a queen, rook, bishop, or knight of the same color, the choice
+being at the discretion of its player (a queen is usually chosen). The choice is not limited to previously captured pieces. Hence it is
+theoretically possible for a player to have up to nine queens or up to ten rooks, bishops, or knights if all of their pawns are promoted.
+If the desired piece is not available, the player should call the arbiter to provide the piece.
+
+
Check
+
+
+
+
A king is in check when it is under attack by one or more enemy pieces. A piece unable to move because it would place its own king in check
+(it is pinned against its own king) may still deliver check to the opposing player.
+
+
A player may not make any move which places or leaves his king in check. The possible ways to get out of check are:
+
+
+
+
Move the king to a square where it is not threatened.
+
Capture the threatening piece (possibly with the king).
+
Block the check by placing a piece between the king and the opponent's threatening piece.
+
+
+
End of the game
+
+
Checkmate
+
+
+
+
If a player's king is placed in check and there is no legal move that player can make to escape check, then the king is said to be checkmated,
+the game ends, and that player loses. Unlike other pieces, the king is never actually captured or removed from the board because checkmate ends
+the game.
+
+
The diagram shows a typical checkmate position. The white king is threatened by the black queen; every square to which the king could move is
+ also threatened; it cannot capture the queen, because it would then be threatened by the rook.
+
+
Draws
+
+
+
+
The game ends in a draw if any of these conditions occur:
+
+
The game is automatically a draw if the player to move is not in check but has no legal move. This situation is called a stalemate.
+ An example of such a position is shown in the diagram to the right.
+
The game is immediately drawn when there is no possibility of checkmate for either side with any series of legal moves. This draw is
+ often due to insufficient material, including the endgames
+
+
king against king;
+
king against king and bishop;
+
king against king and knight;
+
king and bishop against king and bishop, with both bishops on diagonals of the same color.
+
+
+
Both players agree to a draw after one of the players makes such an offer.
+
+
+
The player having the move may claim a draw by declaring that one of the following conditions exists, or by declaring an intention to
+make a move which will bring about one of these conditions:
+
+
+
Fifty-move rule: There has been no capture or pawn move in the last fifty moves by each player.
+
Threefold repetition: The same board position has occurred three times with the same player to move and all pieces having the same
+rights to move, including the right to castle or capture en passant.
+
+
+
If the claim is proven true, the game is drawn.
+
+
At one time, if a player was able to check the opposing king continually (perpetual check) and the player indicated their intention to do so,
+the game was drawn. This rule is no longer in effect; however, players will usually agree to a draw in such a situation, since either the rule on
+threefold repetition or the fifty-move rule will eventually be applicable.
diff --git a/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-thumb.png b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-thumb.png
new file mode 100644
index 00000000..aa6d12ad
Binary files /dev/null and b/src/games/chessbase/res/rules/minjiku-shogi/minjiku-shogi-thumb.png differ
diff --git a/src/games/chessbase/raumschach-credits.html b/src/games/chessbase/res/rules/raumschach/raumschach-credits.html
similarity index 100%
rename from src/games/chessbase/raumschach-credits.html
rename to src/games/chessbase/res/rules/raumschach/raumschach-credits.html
diff --git a/src/games/chessbase/raumschach-description.html b/src/games/chessbase/res/rules/raumschach/raumschach-description.html
similarity index 100%
rename from src/games/chessbase/raumschach-description.html
rename to src/games/chessbase/res/rules/raumschach/raumschach-description.html
diff --git a/src/games/chessbase/raumschach-rules.html b/src/games/chessbase/res/rules/raumschach/raumschach-rules.html
similarity index 100%
rename from src/games/chessbase/raumschach-rules.html
rename to src/games/chessbase/res/rules/raumschach/raumschach-rules.html
diff --git a/src/games/chessbase/raumschach-thumb.png b/src/games/chessbase/res/rules/raumschach/raumschach-thumb.png
similarity index 100%
rename from src/games/chessbase/raumschach-thumb.png
rename to src/games/chessbase/res/rules/raumschach/raumschach-thumb.png
diff --git a/src/games/chessbase/rollerball-credits.html b/src/games/chessbase/res/rules/rollerball/rollerball-credits.html
similarity index 100%
rename from src/games/chessbase/rollerball-credits.html
rename to src/games/chessbase/res/rules/rollerball/rollerball-credits.html
diff --git a/src/games/chessbase/rollerball-description.html b/src/games/chessbase/res/rules/rollerball/rollerball-description.html
similarity index 100%
rename from src/games/chessbase/rollerball-description.html
rename to src/games/chessbase/res/rules/rollerball/rollerball-description.html
diff --git a/src/games/chessbase/rollerball-rules.html b/src/games/chessbase/res/rules/rollerball/rollerball-rules.html
similarity index 100%
rename from src/games/chessbase/rollerball-rules.html
rename to src/games/chessbase/res/rules/rollerball/rollerball-rules.html
diff --git a/src/games/chessbase/rollerball-thumb.png b/src/games/chessbase/res/rules/rollerball/rollerball-thumb.png
similarity index 100%
rename from src/games/chessbase/rollerball-thumb.png
rename to src/games/chessbase/res/rules/rollerball/rollerball-thumb.png
diff --git a/src/games/chessbase/res/rules/scirocco/scirocco-start-setup.png b/src/games/chessbase/res/rules/scirocco/scirocco-start-setup.png
new file mode 100644
index 00000000..ceb293b6
Binary files /dev/null and b/src/games/chessbase/res/rules/scirocco/scirocco-start-setup.png differ
diff --git a/src/games/chessbase/res/rules/scirocco/scirocco-thumb.png b/src/games/chessbase/res/rules/scirocco/scirocco-thumb.png
new file mode 100644
index 00000000..73ad5d28
Binary files /dev/null and b/src/games/chessbase/res/rules/scirocco/scirocco-thumb.png differ
diff --git a/src/games/chessbase/shafran-credits.html b/src/games/chessbase/res/rules/shafran/shafran-credits.html
similarity index 100%
rename from src/games/chessbase/shafran-credits.html
rename to src/games/chessbase/res/rules/shafran/shafran-credits.html
diff --git a/src/games/chessbase/shafran-description.html b/src/games/chessbase/res/rules/shafran/shafran-description.html
similarity index 100%
rename from src/games/chessbase/shafran-description.html
rename to src/games/chessbase/res/rules/shafran/shafran-description.html
diff --git a/src/games/chessbase/shafran-rules.html b/src/games/chessbase/res/rules/shafran/shafran-rules.html
similarity index 100%
rename from src/games/chessbase/shafran-rules.html
rename to src/games/chessbase/res/rules/shafran/shafran-rules.html
diff --git a/src/games/chessbase/shafran-thumb.png b/src/games/chessbase/res/rules/shafran/shafran-thumb.png
similarity index 100%
rename from src/games/chessbase/shafran-thumb.png
rename to src/games/chessbase/res/rules/shafran/shafran-thumb.png
diff --git a/src/games/chessbase/pemba-credits.html b/src/games/chessbase/res/rules/shako/pemba-credits.html
similarity index 100%
rename from src/games/chessbase/pemba-credits.html
rename to src/games/chessbase/res/rules/shako/pemba-credits.html
diff --git a/src/games/chessbase/pemba-description-fr.html b/src/games/chessbase/res/rules/shako/pemba-description-fr.html
similarity index 100%
rename from src/games/chessbase/pemba-description-fr.html
rename to src/games/chessbase/res/rules/shako/pemba-description-fr.html
diff --git a/src/games/chessbase/pemba-description.html b/src/games/chessbase/res/rules/shako/pemba-description.html
similarity index 100%
rename from src/games/chessbase/pemba-description.html
rename to src/games/chessbase/res/rules/shako/pemba-description.html
diff --git a/src/games/chessbase/pemba-rules-fr.html b/src/games/chessbase/res/rules/shako/pemba-rules-fr.html
similarity index 99%
rename from src/games/chessbase/pemba-rules-fr.html
rename to src/games/chessbase/res/rules/shako/pemba-rules-fr.html
index 23e33010..d517c841 100644
--- a/src/games/chessbase/pemba-rules-fr.html
+++ b/src/games/chessbase/res/rules/shako/pemba-rules-fr.html
@@ -28,8 +28,6 @@
-
diff --git a/src/games/chessbase/pemba-rules.html b/src/games/chessbase/res/rules/shako/pemba-rules.html
similarity index 85%
rename from src/games/chessbase/pemba-rules.html
rename to src/games/chessbase/res/rules/shako/pemba-rules.html
index 5e64aa6b..055ea133 100644
--- a/src/games/chessbase/pemba-rules.html
+++ b/src/games/chessbase/res/rules/shako/pemba-rules.html
@@ -32,14 +32,11 @@
Initial setup
The board has 10 x 10 squares.
-
-
-
Pieces
King
-
+
Moves as in usual Chess, except there is no castling.
@@ -48,7 +45,7 @@
King
Queen
-
+
Exactly as in usual Chess.
@@ -57,7 +54,7 @@
Queen
Bishop
-
+
Exactly as in usual Chess.
@@ -66,7 +63,7 @@
Bishop
Knight
-
+
Exactly as in usual Chess.
@@ -75,7 +72,7 @@
Knight
Rook
-
+
Exactly as in usual Chess.
@@ -84,7 +81,7 @@
Rook
Elephant
-
+
Moves one or two squares diagonally. When an Elephant moves two squares, it is allowed to jump, i.e., the intervening square does not have to be empty. The Elephant moves as the combined Alfil and Firzan (Ferz) from Shatranj, two pieces which were also present in mediaeval Chess and have disappeared with the birth of modern moves for Queen and Bishop.
@@ -93,7 +90,7 @@
Elephant
Camel
-
+
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square.
@@ -102,7 +99,7 @@
Camel
Cannon
-
+
moves without taking like a Rook, but it takes by going in a straight horizontal and vertical line and jumping over exactly one piece. When a Cannon takes a piece, there must be exactly one piece between the original and final square of the Cannon's move - this piece may be of either color. (This is identical to the move of the Cannon in Xiangqi.)
@@ -111,7 +108,7 @@
Cannon
Giraffe
-
+
a (3,2) jumper, it jumps to the opposite square of a 3x4 rectangle, like an extended Knight. No matter what intermediate squares contain. Note that it always changes the same color of its square. That piece is found in Alfonso X's Grant Acedrex (but its move has been rendered differently by 20th century historians). The same pattern, but with a non-jumping move, is found in Janggi, Korean Chess, for the Elephant. Under the name of Zebra, it is also a fairy piece used by problemists for compositions.
@@ -121,7 +118,7 @@
Giraffe
Machine
-
+
it is an orthogonal counterpart of the Elephant as it moves 1 or 2 squares orthogonally, jumping over the first square if it is occupied. Then, it combines the moves of old Dabbaba and Wazir found in ancient Muslim Chess variants. The word Dabbaba designated a siege machine at war in Arabic, hence the name given for this piece.
@@ -130,7 +127,7 @@
Machine
Bow
-
+
Crocodile or bow : it is the diagonal counterpart of the Xiangqi's Cannon. It moves like a Bishop (which was named Crocodile in Grant Acedrex) and needs an intermediate piece between itself and its victim to capture it. The Crocodile jumps the intermediate and takes the victim on its square. The intermediate is left unaffected. Also known as Vao by problemists.
diff --git a/src/games/chessbase/pemba-thumb.png b/src/games/chessbase/res/rules/shako/pemba-thumb.png
similarity index 100%
rename from src/games/chessbase/pemba-thumb.png
rename to src/games/chessbase/res/rules/shako/pemba-thumb.png
diff --git a/src/games/chessbase/shako-credits-fr.html b/src/games/chessbase/res/rules/shako/shako-credits-fr.html
similarity index 100%
rename from src/games/chessbase/shako-credits-fr.html
rename to src/games/chessbase/res/rules/shako/shako-credits-fr.html
diff --git a/src/games/chessbase/shako-credits.html b/src/games/chessbase/res/rules/shako/shako-credits.html
similarity index 100%
rename from src/games/chessbase/shako-credits.html
rename to src/games/chessbase/res/rules/shako/shako-credits.html
diff --git a/src/games/chessbase/shako-description-fr.html b/src/games/chessbase/res/rules/shako/shako-description-fr.html
similarity index 100%
rename from src/games/chessbase/shako-description-fr.html
rename to src/games/chessbase/res/rules/shako/shako-description-fr.html
diff --git a/src/games/chessbase/shako-description.html b/src/games/chessbase/res/rules/shako/shako-description.html
similarity index 100%
rename from src/games/chessbase/shako-description.html
rename to src/games/chessbase/res/rules/shako/shako-description.html
diff --git a/src/games/chessbase/shako-rules-fr.html b/src/games/chessbase/res/rules/shako/shako-rules-fr.html
similarity index 100%
rename from src/games/chessbase/shako-rules-fr.html
rename to src/games/chessbase/res/rules/shako/shako-rules-fr.html
diff --git a/src/games/chessbase/shako-rules.html b/src/games/chessbase/res/rules/shako/shako-rules.html
similarity index 100%
rename from src/games/chessbase/shako-rules.html
rename to src/games/chessbase/res/rules/shako/shako-rules.html
diff --git a/src/games/chessbase/shako-thumb.png b/src/games/chessbase/res/rules/shako/shako-thumb.png
similarity index 100%
rename from src/games/chessbase/shako-thumb.png
rename to src/games/chessbase/res/rules/shako/shako-thumb.png
diff --git a/src/games/chessbase/shatranj-credits.html b/src/games/chessbase/res/rules/shatranj/shatranj-credits.html
similarity index 100%
rename from src/games/chessbase/shatranj-credits.html
rename to src/games/chessbase/res/rules/shatranj/shatranj-credits.html
diff --git a/src/games/chessbase/shatranj-description.html b/src/games/chessbase/res/rules/shatranj/shatranj-description.html
similarity index 100%
rename from src/games/chessbase/shatranj-description.html
rename to src/games/chessbase/res/rules/shatranj/shatranj-description.html
diff --git a/src/games/chessbase/shatranj-rules.html b/src/games/chessbase/res/rules/shatranj/shatranj-rules.html
similarity index 100%
rename from src/games/chessbase/shatranj-rules.html
rename to src/games/chessbase/res/rules/shatranj/shatranj-rules.html
diff --git a/src/games/chessbase/shatranj-thumb.png b/src/games/chessbase/res/rules/shatranj/shatranj-thumb.png
similarity index 100%
rename from src/games/chessbase/shatranj-thumb.png
rename to src/games/chessbase/res/rules/shatranj/shatranj-thumb.png
diff --git a/src/games/chessbase/res/rules/shogi/bishop.png b/src/games/chessbase/res/rules/shogi/bishop.png
new file mode 100644
index 00000000..c4772b6b
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/bishop.png differ
diff --git a/src/games/chessbase/res/rules/shogi/chu-shogi-rules.html b/src/games/chessbase/res/rules/shogi/chu-shogi-rules.html
new file mode 100644
index 00000000..d9256d3b
--- /dev/null
+++ b/src/games/chessbase/res/rules/shogi/chu-shogi-rules.html
@@ -0,0 +1,173 @@
+
+
+
Chu Shogi
+
Chu Shogi ('Middle Shogi') has been the dominant form of Chess in Japan for many centuries, until the invention of piece drops caused it to be replaced by modern Shogi.
+
+
Board
+
+
Played on a 12x12 board
+
+
Initial setup
+
+
+
+
Reference Guide
+
+
+
Gold general: moves and captures to adjacent squares in any orthogonal or the forward diagonal direction.
+
+
Silver general: moves and captures to adjacent squares in any diagonal or the forward orthogonal direction.
+
+
Pawn : The Pawn: moves and captures to the square directly in front of it.
+
Rook : as in chess.
+
Bishop : as in chess.
+
King : as in chess.
+
Horse : The Knight has the two forward-most moves of the Chess knight.
+
+
Lance : The Lance moves as a Rook but only forward in the same file, never sideways or backward.
+
+
+
Copper general
+
+
+
Side mover
+
+
+
Vertical Mover
+
+
+
Reverse Chariot
+
+
+
Flying Ox
+
+
+
Free Boar
+
+
+
White Horse
+
+
+
Whale
+
+
+
Drunk Elephant
+
+
+
+
Leopard
+
+
+
Tiger
+
+
+
Go between
+
+
+
+
Kirin: moves and captures to diagonally adjacent squares, or by jumping to the second square orthogonally.
+
+
+
Phoenix: moves and captures to orthogonally adjacent squares, or by jumping to the second square diagonally.
+
+
+
Stag
+
+
+
Prince
+
+
+
Queen
+
+
+
Falcon: Move like a queen except vertically forward where it has a form of Lion Power. It can make up to two steps, continuing after a capture, but only along the same ray. So for the (optional) second step they can only decide if they want to continue in the same direction, or move back to their starting square
+
+
+
Eagle: Move like a queen except diagonnaly forward where it has a form of Lion Power. It can make up to two steps, continuing after a capture, but only along the same ray. So for the (optional) second step they can only decide if they want to continue in the same direction, or move back to their starting square
+
+
+
Lion: A Lion moves as King, but up to twice per turn, in independent directions, also if the first King move captures something. The ability to move on after a capture is called 'Lion power'. The combination of two steps can also be taken as a hop, i.e. over an occupied square without disturbing it, when it does not return to the starting square. So the Lion can:
+
+
move or capture by leaping to any square in the 5x5 area surrounding it,
+
capture an adjacent piece, and then go on moving or capturing once more as a King,
+
move to an adjacent empty square and back, effectively passing a turn.
+
+
+
+
+
+
Restrictions on Lion trading : To conserve the Lions, there are restrictions on capturing those, aiming to prevent elimination of two Lions in consecutive turns.
+
A non-Lion cannot capture a Lion when on the previous turn a Lion was captured by a non-Lion on another square. ('counter-strike')
+
A Lion cannot capture a Lion if that would expose it to recapture in the next turn, as if it had become an absolute royal for one turn. ('protected')
+
A non-Lion cannot capture a Lion when on the previous turn a Lion was captured by a non-Lion on another square. ('counter-strike')
+
Promotion
+
+
+
+
>
+
>
+
>
+
>
+
+
+
>
+
>
+
>
+
>
+
+
+
>
+
>
+
+
+
>
+
>
+
+
+
>
+
>
+
+
+
>
+
+
+
>
+
+
+
>
+
+
+
>
+
+
+
>
+
+
+
+
+
+
+
diff --git a/src/games/chessbase/res/rules/shogi/chu-shogi-thumb.png b/src/games/chessbase/res/rules/shogi/chu-shogi-thumb.png
new file mode 100644
index 00000000..f2ee53a7
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/chu-shogi-thumb.png differ
diff --git a/src/games/chessbase/res/rules/shogi/gold.png b/src/games/chessbase/res/rules/shogi/gold.png
new file mode 100644
index 00000000..df73c663
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/gold.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/boar.png b/src/games/chessbase/res/rules/shogi/graphs/boar.png
new file mode 100644
index 00000000..f450029a
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/boar.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/chariot.png b/src/games/chessbase/res/rules/shogi/graphs/chariot.png
new file mode 100644
index 00000000..ac525dfc
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/chariot.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/copper.png b/src/games/chessbase/res/rules/shogi/graphs/copper.png
new file mode 100644
index 00000000..35422e2a
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/copper.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/drunk-elephant.png b/src/games/chessbase/res/rules/shogi/graphs/drunk-elephant.png
new file mode 100644
index 00000000..67656dd0
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/drunk-elephant.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/eagle.png b/src/games/chessbase/res/rules/shogi/graphs/eagle.png
new file mode 100644
index 00000000..1372e08e
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/eagle.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/falcon.png b/src/games/chessbase/res/rules/shogi/graphs/falcon.png
new file mode 100644
index 00000000..ce1c4bf7
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/falcon.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/flying-ox.png b/src/games/chessbase/res/rules/shogi/graphs/flying-ox.png
new file mode 100644
index 00000000..2370fd50
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/flying-ox.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/flying-stag.png b/src/games/chessbase/res/rules/shogi/graphs/flying-stag.png
new file mode 100644
index 00000000..d29ba6bc
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/flying-stag.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/go-between.png b/src/games/chessbase/res/rules/shogi/graphs/go-between.png
new file mode 100644
index 00000000..33cbb9be
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/go-between.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/left-quail.png b/src/games/chessbase/res/rules/shogi/graphs/left-quail.png
new file mode 100644
index 00000000..0acb1973
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/left-quail.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/leopard.png b/src/games/chessbase/res/rules/shogi/graphs/leopard.png
new file mode 100644
index 00000000..c838ac10
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/leopard.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/montain-eagle.png b/src/games/chessbase/res/rules/shogi/graphs/montain-eagle.png
new file mode 100644
index 00000000..d74ebc39
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/montain-eagle.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/pheasant.png b/src/games/chessbase/res/rules/shogi/graphs/pheasant.png
new file mode 100644
index 00000000..a7d45dd3
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/pheasant.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/right-quail.png b/src/games/chessbase/res/rules/shogi/graphs/right-quail.png
new file mode 100644
index 00000000..08009164
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/right-quail.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/shogi-horse.png b/src/games/chessbase/res/rules/shogi/graphs/shogi-horse.png
new file mode 100644
index 00000000..8ba30c7b
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/shogi-horse.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/shogi-lance.png b/src/games/chessbase/res/rules/shogi/graphs/shogi-lance.png
new file mode 100644
index 00000000..da49f775
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/shogi-lance.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/shogi-prince.png b/src/games/chessbase/res/rules/shogi/graphs/shogi-prince.png
new file mode 100644
index 00000000..86234b0f
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/shogi-prince.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/side-mover.png b/src/games/chessbase/res/rules/shogi/graphs/side-mover.png
new file mode 100644
index 00000000..8d85a514
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/side-mover.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/tiger.png b/src/games/chessbase/res/rules/shogi/graphs/tiger.png
new file mode 100644
index 00000000..f7afe541
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/tiger.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/vertical-mover.png b/src/games/chessbase/res/rules/shogi/graphs/vertical-mover.png
new file mode 100644
index 00000000..b418b9be
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/vertical-mover.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/whale.png b/src/games/chessbase/res/rules/shogi/graphs/whale.png
new file mode 100644
index 00000000..59f098bf
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/whale.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/white-horse.png b/src/games/chessbase/res/rules/shogi/graphs/white-horse.png
new file mode 100644
index 00000000..969e4f67
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/white-horse.png differ
diff --git a/src/games/chessbase/res/rules/shogi/graphs/wild-goose.png b/src/games/chessbase/res/rules/shogi/graphs/wild-goose.png
new file mode 100644
index 00000000..a2d9f590
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/graphs/wild-goose.png differ
diff --git a/src/games/chessbase/res/rules/shogi/horse.png b/src/games/chessbase/res/rules/shogi/horse.png
new file mode 100644
index 00000000..a94727f9
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/horse.png differ
diff --git a/src/games/chessbase/res/rules/shogi/king.png b/src/games/chessbase/res/rules/shogi/king.png
new file mode 100644
index 00000000..18cf2056
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/king.png differ
diff --git a/src/games/chessbase/res/rules/shogi/lance.png b/src/games/chessbase/res/rules/shogi/lance.png
new file mode 100644
index 00000000..d8c89657
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/lance.png differ
diff --git a/src/games/chessbase/res/rules/shogi/mini-shogi-initial-2d-western.png b/src/games/chessbase/res/rules/shogi/mini-shogi-initial-2d-western.png
new file mode 100644
index 00000000..19ef627a
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/mini-shogi-initial-2d-western.png differ
diff --git a/src/games/chessbase/res/rules/shogi/mini-shogi-initial-2d.png b/src/games/chessbase/res/rules/shogi/mini-shogi-initial-2d.png
new file mode 100644
index 00000000..a0451d88
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/mini-shogi-initial-2d.png differ
diff --git a/src/games/chessbase/res/rules/shogi/mini-shogi-initial-3d.png b/src/games/chessbase/res/rules/shogi/mini-shogi-initial-3d.png
new file mode 100644
index 00000000..2d82e545
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/mini-shogi-initial-3d.png differ
diff --git a/src/games/chessbase/res/rules/shogi/mini-shogi-rules.html b/src/games/chessbase/res/rules/shogi/mini-shogi-rules.html
new file mode 100644
index 00000000..0ea119bd
--- /dev/null
+++ b/src/games/chessbase/res/rules/shogi/mini-shogi-rules.html
@@ -0,0 +1,69 @@
+
+
Mini-shogi is a well known variant of Shogi (Japanese Chess).
+
+
To win you have to checkmate the king of your opponent.
+
+
Board
+
+
The board is a 5x5
+
+
Pieces
+
+
for each team:
+
+
1 King
+
1 Gold general
+
1 Silver general
+
1 Bishop
+
1 Rook
+
1 Pawn
+
+
+
+
+
+
Initial setup
+
+
+
A skin with pictograms is available for players not familiar with the traditional japanese version.
+
+
+
Pieces actions and properties
+
+
Gold general: moves and captures to adjacent squares in any orthogonal or the forward diagonal direction.
+
+
Silver general: moves and captures to adjacent squares in any diagonal or the forward orthogonal direction.
+
+
Pawn : The Pawn: moves and captures to the square directly in front of it.
+
Rook : as in chess.
+
Bishop : as in chess.
+
King : as in chess.
+
+
Promotion
+
+
+
Silver general and pawn promote to gold general
+
Rook and bishop gain king move with promotion
+
+
+
Drops
+
Captured pieces become prisoners and lose their promotion, guarded on your right. You can use your turn to put them back into play. A player can either move one of his pieces or drop a prisoner back into play on his behalf.
+
+
A pawn can’t be dropped on a column with an unpromoted pawn of the same color.
+
+
A pawn can’t make an immediate checkmate when dropped. It is allowed for other pieces.
+
+
A piece can’t be dropped is no subsequent move is possible, so a pawn cannot be dropped on the last line.
+
+
Available skins
+
2D skins are available for all, 3D skins need WebGL so please use Chrome or Firefox.
diff --git a/src/games/chessbase/res/rules/shogi/shogi-initial-2d-western.png b/src/games/chessbase/res/rules/shogi/shogi-initial-2d-western.png
new file mode 100644
index 00000000..afffbb56
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/shogi-initial-2d-western.png differ
diff --git a/src/games/chessbase/res/rules/shogi/shogi-initial-2d.png b/src/games/chessbase/res/rules/shogi/shogi-initial-2d.png
new file mode 100644
index 00000000..5f8e13af
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/shogi-initial-2d.png differ
diff --git a/src/games/chessbase/res/rules/shogi/shogi-rules.html b/src/games/chessbase/res/rules/shogi/shogi-rules.html
new file mode 100644
index 00000000..f384e2b0
--- /dev/null
+++ b/src/games/chessbase/res/rules/shogi/shogi-rules.html
@@ -0,0 +1,72 @@
+
+
Shogi (Japanese Chess)
+
Shogi is the Japanese cousin of Chess. Very similar to it in some respects, it differs from Chess mainly by allowing players to keep captured pieces and replay them as their own. To win you have to checkmate the king of your opponent.
+
+
Board
+
+
The board is a 9x9
+
+
Pieces
+
+
for each team:
+
+
1 King
+
2 Gold generals
+
2 Silver generals
+
1 Bishop
+
1 Rook
+
2 lances
+
2 Horses
+
9 Pawns
+
+
+
+
Initial setup
+
+
+
A skin with pictograms is available for players not familiar with the traditional japanese version.
+
+
+
Pieces actions and properties
+
+
+
Gold general: moves and captures to adjacent squares in any orthogonal or the forward diagonal direction.
+
+
Silver general: moves and captures to adjacent squares in any diagonal or the forward orthogonal direction.
+
+
Pawn : The Pawn: moves and captures to the square directly in front of it.
+
Rook : as in chess.
+
Bishop : as in chess.
+
King : as in chess.
+
Horse : The Knight has the two forward-most moves of the Chess knight.
+
+
Lance : The Lance moves as a Rook but only forward in the same file, never sideways or backward.
+
+
Promotion
+
+
+
Silver general, horse, lance and pawn promote to gold general
+
Rook and bishop gain king move with promotion
+
+
+
Drops
+
Captured pieces become prisoners and lose their promotion, guarded on your right. You can use your turn to put them back into play. A player can either move one of his pieces or drop a prisoner back into play on his behalf.
+
+
A pawn can’t be dropped on a column with an unpromoted pawn of the same color.
+
+
A pawn can’t make an immediate checkmate when dropped. It is allowed for other pieces.
+
+
A piece can’t be dropped is no subsequent move is possible, so a pawn cannot be dropped on the last line.
+
+
Available skins
+
2D skins are available for all, 3D skins need WebGL so please use Chrome or Firefox.
+
+
diff --git a/src/games/chessbase/res/rules/shogi/shogi-thumb.png b/src/games/chessbase/res/rules/shogi/shogi-thumb.png
new file mode 100644
index 00000000..c9a55bb7
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/shogi-thumb.png differ
diff --git a/src/games/chessbase/res/rules/shogi/silver.png b/src/games/chessbase/res/rules/shogi/silver.png
new file mode 100644
index 00000000..42dbeda3
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/silver.png differ
diff --git a/src/games/chessbase/res/rules/shogi/tori-shogi-description.html b/src/games/chessbase/res/rules/shogi/tori-shogi-description.html
new file mode 100644
index 00000000..5eaaedc1
--- /dev/null
+++ b/src/games/chessbase/res/rules/shogi/tori-shogi-description.html
@@ -0,0 +1,40 @@
+
Tori Shogi ('Bird Shogi') is a variant of Japanese Chess on a smaller board,
+whith mostly different pieces
+It was invented by Toyota Genryu in 1799.
+
+
Only the Pawns and King move as in regular Shogi, even though they are called differently here.
+Apart from the Pawns only one other piece can promote,
+and the Pawn promotes to a quite weak piece.
+This prevents the possibility of an impasse when both royals enter their promotion zone.
+Otherwise the rules are identical to modern Shogi,
+except that there can be two Pawns in each file.
+
+
+
+
A skin with pictograms is available for players not familiar with the traditional japanese version.
+
+
+
Board
+
+
The board is a 7x7
+
+
Pieces
+
+
for each team:
+
+
1 Phoenix
+
1 Falcon
+
2 Cranes
+
2 Pheasants
+
2 Quails (a left and a right)
+
8 Swallows
+
+
+
+
+
Pieces actions and properties
+
+
+
Pheasant: moves and captures to adjacent squares in any orthogonal or the forward diagonal direction.
+
+
Phoenix : as the King in chess.
diff --git a/src/games/chessbase/res/rules/shogi/tori-shogi-initial-2d-pictos.png b/src/games/chessbase/res/rules/shogi/tori-shogi-initial-2d-pictos.png
new file mode 100644
index 00000000..7b5ce76b
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/tori-shogi-initial-2d-pictos.png differ
diff --git a/src/games/chessbase/res/rules/shogi/tori-shogi-rules.html b/src/games/chessbase/res/rules/shogi/tori-shogi-rules.html
new file mode 100644
index 00000000..925e6a42
--- /dev/null
+++ b/src/games/chessbase/res/rules/shogi/tori-shogi-rules.html
@@ -0,0 +1,52 @@
+
+
Tori Shogi ('Bird Shogi') is a variant of Japanese Chess on a smaller board.
+
+
To win you have to checkmate the Phoenix of your opponent.
+
A skin with pictograms is available for players not familiar with the traditional japanese version.
+
+
+
Board
+
+
The board is a 7x7
+
+
Pieces
+
+
for each team:
+
+
1 Phoenix
+
1 Falcon
+
2 Cranes
+
2 Pheasants
+
2 Quails (a left and a right)
+
8 Swallows
+
+
+
+
+
Pieces actions and properties
+
+
Phoenix : as the King in shogi.
+
Swallow : as the Pawn in shogi.
+
Crane : as the ferocious leopard in chu shogi.
+
+
Falcon : as drunk elephant in chu shogi.
+
+
Pheasant: moves and captures to adjacent squares in any orthogonal or the forward diagonal direction.
+
+
Wild Goose: The goose can jump to the second square directly backward or diagonally forward.
+
+
Quail: The quail can move one square diagonally either left (left quail) or right (right quail) and any number of free squares directly forward or diagonally backward.
+
+
Montain Eagle: The eagle can move any number of free squares diagonally forward or directly backward; or, it can move one or two squares diagonally backward; or, it can step one square directly forward or sideways.
+
+
+
+
+
diff --git a/src/games/chessbase/res/rules/shogi/tori-shogi-thumb.png b/src/games/chessbase/res/rules/shogi/tori-shogi-thumb.png
new file mode 100644
index 00000000..1592b356
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/tori-shogi-thumb.png differ
diff --git a/src/games/chessbase/res/rules/shogi/w-whale.png b/src/games/chessbase/res/rules/shogi/w-whale.png
new file mode 100644
index 00000000..19b2acd5
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/w-whale.png differ
diff --git a/src/games/chessbase/res/rules/shogi/wild-goose.png b/src/games/chessbase/res/rules/shogi/wild-goose.png
new file mode 100644
index 00000000..8a7633ee
Binary files /dev/null and b/src/games/chessbase/res/rules/shogi/wild-goose.png differ
diff --git a/src/games/chessbase/res/rules/spartan/spartan-initial.jpg b/src/games/chessbase/res/rules/spartan/spartan-initial.jpg
new file mode 100644
index 00000000..e8625814
Binary files /dev/null and b/src/games/chessbase/res/rules/spartan/spartan-initial.jpg differ
diff --git a/src/games/chessbase/knight-inv-thumbnail.png b/src/games/chessbase/res/rules/standard/knight-inv-thumbnail.png
similarity index 100%
rename from src/games/chessbase/knight-inv-thumbnail.png
rename to src/games/chessbase/res/rules/standard/knight-inv-thumbnail.png
diff --git a/src/games/chessbase/losing-rules.html b/src/games/chessbase/res/rules/standard/losing-rules.html
similarity index 100%
rename from src/games/chessbase/losing-rules.html
rename to src/games/chessbase/res/rules/standard/losing-rules.html
diff --git a/src/games/chessbase/romanchenko-credits.html b/src/games/chessbase/res/rules/standard/romanchenko-credits.html
similarity index 100%
rename from src/games/chessbase/romanchenko-credits.html
rename to src/games/chessbase/res/rules/standard/romanchenko-credits.html
diff --git a/src/games/chessbase/romanchenko-description.html b/src/games/chessbase/res/rules/standard/romanchenko-description.html
similarity index 100%
rename from src/games/chessbase/romanchenko-description.html
rename to src/games/chessbase/res/rules/standard/romanchenko-description.html
diff --git a/src/games/chessbase/romanchenko-rules.html b/src/games/chessbase/res/rules/standard/romanchenko-rules.html
similarity index 100%
rename from src/games/chessbase/romanchenko-rules.html
rename to src/games/chessbase/res/rules/standard/romanchenko-rules.html
diff --git a/src/games/chessbase/romanchenko-thumb.png b/src/games/chessbase/res/rules/standard/romanchenko-thumb.png
similarity index 100%
rename from src/games/chessbase/romanchenko-thumb.png
rename to src/games/chessbase/res/rules/standard/romanchenko-thumb.png
diff --git a/src/games/chessbase/sweet16-credits.html b/src/games/chessbase/res/rules/standard/sweet16-credits.html
similarity index 100%
rename from src/games/chessbase/sweet16-credits.html
rename to src/games/chessbase/res/rules/standard/sweet16-credits.html
diff --git a/src/games/chessbase/sweet16-description.html b/src/games/chessbase/res/rules/standard/sweet16-description.html
similarity index 100%
rename from src/games/chessbase/sweet16-description.html
rename to src/games/chessbase/res/rules/standard/sweet16-description.html
diff --git a/src/games/chessbase/sweet16-rules.html b/src/games/chessbase/res/rules/standard/sweet16-rules.html
similarity index 100%
rename from src/games/chessbase/sweet16-rules.html
rename to src/games/chessbase/res/rules/standard/sweet16-rules.html
diff --git a/src/games/chessbase/sweet16-thumb.png b/src/games/chessbase/res/rules/standard/sweet16-thumb.png
similarity index 100%
rename from src/games/chessbase/sweet16-thumb.png
rename to src/games/chessbase/res/rules/standard/sweet16-thumb.png
diff --git a/src/games/chessbase/res/rules/team-mate/acromantula.png b/src/games/chessbase/res/rules/team-mate/acromantula.png
new file mode 100644
index 00000000..648447c3
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/acromantula.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/adjutant.png b/src/games/chessbase/res/rules/team-mate/adjutant.png
new file mode 100644
index 00000000..53db9185
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/adjutant.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/brute.png b/src/games/chessbase/res/rules/team-mate/brute.png
new file mode 100644
index 00000000..30923338
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/brute.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/cobra.png b/src/games/chessbase/res/rules/team-mate/cobra.png
new file mode 100644
index 00000000..7afcd2ac
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/cobra.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/elephant.png b/src/games/chessbase/res/rules/team-mate/elephant.png
new file mode 100644
index 00000000..14ac5649
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/elephant.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/mortar.png b/src/games/chessbase/res/rules/team-mate/mortar.png
new file mode 100644
index 00000000..41e4744a
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/mortar.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/phoenix.png b/src/games/chessbase/res/rules/team-mate/phoenix.png
new file mode 100644
index 00000000..3de4e487
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/phoenix.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/team-mate-credits.html b/src/games/chessbase/res/rules/team-mate/team-mate-credits.html
new file mode 100644
index 00000000..667e0cd4
--- /dev/null
+++ b/src/games/chessbase/res/rules/team-mate/team-mate-credits.html
@@ -0,0 +1,11 @@
+
Game rules
+
+Team-mate chess has been invented by H.G.Muller in 2014
+
Site: .
+
+
Jocly implementation
+
+
+
Development: Michel gutierrez (@_mig_) and H.G.Muller (@hgm)
diff --git a/src/games/chessbase/res/rules/team-mate/team-mate-description.html b/src/games/chessbase/res/rules/team-mate/team-mate-description.html
new file mode 100644
index 00000000..6c4563f6
--- /dev/null
+++ b/src/games/chessbase/res/rules/team-mate/team-mate-description.html
@@ -0,0 +1,14 @@
+
Team-mate chess is a variant with many different unusual pieces.
+
+
The idea behind team-mate chess was to have a variant where no single piece would be able (with the help of its own king) to force checkmate onto a bare king,
+but where you would always need at least a pair of pieces (a 'team') to do that.
+So that all basic checkmates become similar to the bishop + knight checkmate of orthodox Chess.
+To get as many such different end-games as possible,
+all pieces in the initial setup are different.
+Furthermore, a piece type not present initially can be obtained through promotion.
+
+
+
Team-mate chess was conceived in 2014 by H.G.Muller.
+
+
+
diff --git a/src/games/chessbase/res/rules/team-mate/team-mate-rules.html b/src/games/chessbase/res/rules/team-mate/team-mate-rules.html
new file mode 100644
index 00000000..883c50b0
--- /dev/null
+++ b/src/games/chessbase/res/rules/team-mate/team-mate-rules.html
@@ -0,0 +1,126 @@
+
Team-mate chess is a chess variant on an 8x8 board.
+
+
Except for the king and one knight all other pieces on the back rank are unorthodox, and different from each other.
+From a-file to h-file each player has a unicorn, a phoenix, an elephant, an acromantula, a king, a mortar, a knight and a cobra.
+The king can castle in the usual way with the unicorn or the cobra.
+Pawns are normal FIDE pawns, except that they can promote only to one of the initially-present pieces other than king or acromantula,
+or to the (not-initially present) Adjutant or Brute.
+From weak to strong the pieces are:
+
+
+
The Brute
+
+
+
+
+
+
Steps one square diagonally or straight back, but cannot capture non-royal pieces.
+It does check a King in the same way as it moves.
+
+
+
The Mortar
+
+
+
+
+
+
Jumps directly to the 2nd or 3rd square diagonally, i.e jumping over any occupied intermediate square.
+
+
+
The Elephant
+
+
+
+
+
+
Steps diagonally one or two squares, leaping over the intermediate square if it is occupied.
+
+
+
The Phoenix
+
+
+
+
+
+
Steps one square orthogonally,
+or jumps two squares diagonally,
+leaping over the intermediate square if it is occupied.
+
+
+
The Unicorn
+
+
+
+
+
+
Steps one square orthogonally, or moves like an orthodox knight.
+
+
+
The Cobra
+
+
+
+
+
+
Moves like an orthodox knight, but when this lands on an empty square,
+it can optionally slide on to the next square in the long direction of the initial knight jump.
+
+
+
The Adjutant
+
+
+
+
+
+
Moves like an orthodox bishop,
+or like a rook that moves only an even number of steps,
+unobstructed by anything an odd number odd squares away.
+
+
+
The Acromantula
+
+
+
+
+
+
Slides along a bent trajectory,
+starting with an orthogonal step,
+and then continuing in an outward diagonal direction.
+It cannot pass beyond any obstacle it encounters along this path.
+
+
+
+
+
+
+
The king, knight and pawn move like in orthodox chess; also castling is as in usual chess, with the pieces in the corners as partner.
+Pawns promote on the eighth row of the board to Mortar, Elephant, Phoenix, Knight, Unicorn, Cobra, Adjutant, or a pair of Brutes, to the owning players choice.
+In the latter case one Brute appears on the promotion square as usual, the other on the square the Pawn came from.
+
+
A draw can be claimed after 64 moves (rather than 50) without capture or pawn advance.
+
+
Other rules are as in orthodox chess. White starts to play.
+
+
Pieces
+
+
Each player commands 16 pieces.
+
+
1 king
+
1 acromantula
+
1 cobra
+
1 unicorn
+
1 knight
+
1 phoenix
+
1 elephant
+
1 mortar
+
8 pawns
+
+
+
+
Initial setup
+
+
+
+
+
+
diff --git a/src/games/chessbase/res/rules/team-mate/team-mate-start-setup.jpg b/src/games/chessbase/res/rules/team-mate/team-mate-start-setup.jpg
new file mode 100644
index 00000000..fe66c5cf
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/team-mate-start-setup.jpg differ
diff --git a/src/games/chessbase/res/rules/team-mate/team-mate-thumb.png b/src/games/chessbase/res/rules/team-mate/team-mate-thumb.png
new file mode 100644
index 00000000..139eeeb3
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/team-mate-thumb.png differ
diff --git a/src/games/chessbase/res/rules/team-mate/unicorn.png b/src/games/chessbase/res/rules/team-mate/unicorn.png
new file mode 100644
index 00000000..ac86d592
Binary files /dev/null and b/src/games/chessbase/res/rules/team-mate/unicorn.png differ
diff --git a/src/games/chessbase/terachess-credits.html b/src/games/chessbase/res/rules/terachess/terachess-credits.html
similarity index 100%
rename from src/games/chessbase/terachess-credits.html
rename to src/games/chessbase/res/rules/terachess/terachess-credits.html
diff --git a/src/games/chessbase/terachess-description.html b/src/games/chessbase/res/rules/terachess/terachess-description.html
similarity index 100%
rename from src/games/chessbase/terachess-description.html
rename to src/games/chessbase/res/rules/terachess/terachess-description.html
diff --git a/src/games/chessbase/terachess-rules.html b/src/games/chessbase/res/rules/terachess/terachess-rules.html
similarity index 99%
rename from src/games/chessbase/terachess-rules.html
rename to src/games/chessbase/res/rules/terachess/terachess-rules.html
index c054c855..82d5227f 100644
--- a/src/games/chessbase/terachess-rules.html
+++ b/src/games/chessbase/res/rules/terachess/terachess-rules.html
@@ -108,7 +108,7 @@
Corporal
Prince
-
+
This piece is simply a non-royal King combined with a Pawn. It can be found in Metamachy and has been inspired by medieval games like the Courier chess , an old chess variant, played in Germany, where it is called "Man". It moves one square in an arbitrary direction, like the King, but without being hindered by check. Here, like the Pawn, he can move without capturing to the second square straight ahead. When the Prince reaches the last row it promotes to an Amazon.
diff --git a/src/games/chessbase/terachess-thumb.png b/src/games/chessbase/res/rules/terachess/terachess-thumb.png
similarity index 100%
rename from src/games/chessbase/terachess-thumb.png
rename to src/games/chessbase/res/rules/terachess/terachess-thumb.png
diff --git a/src/games/chessbase/kaisergame-credits.html b/src/games/chessbase/res/rules/tressau/kaisergame-credits.html
similarity index 100%
rename from src/games/chessbase/kaisergame-credits.html
rename to src/games/chessbase/res/rules/tressau/kaisergame-credits.html
diff --git a/src/games/chessbase/kaisergame-description.html b/src/games/chessbase/res/rules/tressau/kaisergame-description.html
similarity index 100%
rename from src/games/chessbase/kaisergame-description.html
rename to src/games/chessbase/res/rules/tressau/kaisergame-description.html
diff --git a/src/games/chessbase/kaisergame-rules.html b/src/games/chessbase/res/rules/tressau/kaisergame-rules.html
similarity index 100%
rename from src/games/chessbase/kaisergame-rules.html
rename to src/games/chessbase/res/rules/tressau/kaisergame-rules.html
diff --git a/src/games/chessbase/kaisergame-thumb.png b/src/games/chessbase/res/rules/tressau/kaisergame-thumb.png
similarity index 100%
rename from src/games/chessbase/kaisergame-thumb.png
rename to src/games/chessbase/res/rules/tressau/kaisergame-thumb.png
diff --git a/src/games/chessbase/sultangame-credits.html b/src/games/chessbase/res/rules/tressau/sultangame-credits.html
similarity index 100%
rename from src/games/chessbase/sultangame-credits.html
rename to src/games/chessbase/res/rules/tressau/sultangame-credits.html
diff --git a/src/games/chessbase/sultangame-description.html b/src/games/chessbase/res/rules/tressau/sultangame-description.html
similarity index 100%
rename from src/games/chessbase/sultangame-description.html
rename to src/games/chessbase/res/rules/tressau/sultangame-description.html
diff --git a/src/games/chessbase/sultangame-rules.html b/src/games/chessbase/res/rules/tressau/sultangame-rules.html
similarity index 100%
rename from src/games/chessbase/sultangame-rules.html
rename to src/games/chessbase/res/rules/tressau/sultangame-rules.html
diff --git a/src/games/chessbase/sultangame-thumb.png b/src/games/chessbase/res/rules/tressau/sultangame-thumb.png
similarity index 100%
rename from src/games/chessbase/sultangame-thumb.png
rename to src/games/chessbase/res/rules/tressau/sultangame-thumb.png
diff --git a/src/games/chessbase/res/rules/werewolf/werewolf-credits.html b/src/games/chessbase/res/rules/werewolf/werewolf-credits.html
new file mode 100644
index 00000000..f55b11ab
--- /dev/null
+++ b/src/games/chessbase/res/rules/werewolf/werewolf-credits.html
@@ -0,0 +1,9 @@
+
Graphic design: Michel gutierrez (@_mig_) and Jérôme Choain (@jcfrog)
+
diff --git a/src/games/chessbase/res/rules/werewolf/werewolf-description.html b/src/games/chessbase/res/rules/werewolf/werewolf-description.html
new file mode 100644
index 00000000..524d8080
--- /dev/null
+++ b/src/games/chessbase/res/rules/werewolf/werewolf-description.html
@@ -0,0 +1,19 @@
+
Werewolf Chess is orthodox Chess with the Queen replaced by a similar, but contageous piece
+
+
+Contagion is a game mechanic that first appeared in Maka Dai Dai Shogi,
+a large Shogi variant created by Japanese Buddhist monks in the Edo period.
+It is one of the methods to ensure the most powerful piece(s) cannot be easily traded out of the game.
+The idea is that when you capture a contageous piece, (in this case the Werewolf),
+the capturing piece instantly promotes to (i.e. changes into) a Werewolf.
+
+
+This profoundly changes the way tactics works, and ensures that after an exchange involving Werewolfs a Werewolf will remain.
+An attempt to trade Werewolfs will thus only lead to disappearance of one of the Werewolfs,
+strongly discouraging the player that would be left without one to engage in such a trade.
+
+
+To make the King not entirely defenseless against a Werewolf, he is immune to the contagion, and can thus safely capture a Werewolf.
+This will provide a way for all Werewolfs to disappear, but only when the King participates in tactic.
+(So usually not before the end-game.)
+
diff --git a/src/games/chessbase/res/rules/werewolf/werewolf-initial.jpg b/src/games/chessbase/res/rules/werewolf/werewolf-initial.jpg
new file mode 100644
index 00000000..0ac0a27d
Binary files /dev/null and b/src/games/chessbase/res/rules/werewolf/werewolf-initial.jpg differ
diff --git a/src/games/chessbase/res/rules/werewolf/werewolf-rules.html b/src/games/chessbase/res/rules/werewolf/werewolf-rules.html
new file mode 100644
index 00000000..5689e253
--- /dev/null
+++ b/src/games/chessbase/res/rules/werewolf/werewolf-rules.html
@@ -0,0 +1,290 @@
+
+
Differences from orthodox chess
+
In Werewolf Chess the Queens are replaced by Werewolfs, and Pawns can only promote to Rook, Bishop or Knight.
+All other rules are the same as in orthodox Chess.
+The Werewolf, however, is contageous:
+a piece capturing a Werewolf instantly turns into a Werewolf itself.
+Only Kings are immune to this.
+
+
+
The Werewolf: moves and captures like a Queen,
+but not more than 3 squares away.
+It can jump to the 2nd square in any direction even if the 1st square is occupied (but then must end its move there).
+If it makes such a jump over an enemy piece,
+the latter can be optionally removed from the board,
+possibly in addition to what was captured on the destination square.
+
+
+
+
Inital setup
+
+
+
+
Each player starts with:
+
+
8 Pawns
+
2 Rooks
+
2 Knights
+
2 Bishops
+
1 Werewolf
+
1 King
+
+
+
+
+
+
Castling: yes.
+
Double move for Pawns (start): yes.
+
"En passant" capture: yes.
+
Promotion: only to the participating orthodox chess pieces (Knight, Bishop, Rook).
+
Contagion: any non-royal that captures a Werewolf turns into a Werewolf of its own color.
Chess is a game played by two people on a chessboard, with sixteen pieces (of six types) for each player. Each type of piece moves in a distinct way.
+The goal of the game is to checkmate, i.e. to threaten the opponent's king with inevitable capture. In addition, there are several ways that a game can end in a draw.
+
+
Initial setup
+
+
+
Chess is played on a chessboard, a square board divided into 64 squares (eight-by-eight) of alternating color, which is similar to that used in
+draughts (checkers). No matter what the actual colors of the board, the lighter-colored squares are called "light" or "white", and the darker-colored squares
+are called "dark" or "black". Sixteen "white" and sixteen "black" pieces are placed on the board at the beginning of the game. The board is placed so that a
+white square is in each player's near-right corner.
+
+
Each player controls sixteen pieces:
+
+
+
+
Name
Number
White Symbols
Black Symbols
+
+
+
King
+
1
+
+
+
+
+
Queen
+
1
+
+
+
+
+
Rook
+
2
+
+
+
+
+
Bishop
+
2
+
+
+
+
+
Knight
+
2
+
+
+
+
+
Pawn
+
8
+
+
+
+
+
+
At the beginning of the game, the pieces are arranged as shown in the diagram. The second row from the player contains the eight pawns;
+the row nearest the player contains the remaining pieces. Popular phrases used to remember the setup, often heard in beginners' clubs,
+are "queen on her own color" and "white on right". The latter refers to setting up the board so that the square closest to each player's right
+is white.
+
+
Play of the game
+
+
The player controlling the white army is named "White"; the player controlling the black pieces is named "Black". White moves first,
+then players alternate moves. Making a move is required; it is not legal to skip a move, even when having to move is detrimental. Play
+continues until a king is checkmated, a player resigns, or a draw is declared, as explained below. In addition, if the game is being played
+under a time control players who exceed their time limit lose the game.
+
+
Movement
+
+
Basic moves
+
+
Each chess piece has its own method of movement. Moves are made to vacant squares except when capturing an opponent's piece.
+
+
With the exception of any movement of the knight and the occasional castling maneuver, pieces cannot jump over each other. When a piece is
+captured (or taken), the attacking piece replaces the enemy piece on its square (en passant being the only exception). The captured piece is
+thus removed from the game and may not be returned to play for the remainder of the game. The king can be put in check but cannot be
+captured (see below).
+
+
+
King
+
+
The king can move exactly one square horizontally, vertically, or diagonally. Only once per player, per game, is a king allowed to make a
+ special move known as castling (see below).
+
+
+
Rooks
+
+
The rook moves any number of vacant squares vertically or horizontally. It also is moved while castling.
+
+
+
Bishops
+
+
The bishop moves any number of vacant squares in any diagonal direction.
+
+
+
Queen
+
+
The queen can move any number of vacant squares diagonally, horizontally, or vertically.
+
+
+
Knights
+
+
The knight moves to the nearest square not on the same rank, file, or diagonal. In other words, the knight moves
+two squares horizontally then one square vertically, or one square horizontally then two squares vertically. Its move is not
+blocked by other pieces: it jumps to the new location.
+
+
+
Pawns
+
+
Pawns have the most complex rules of movement:
+
+
A pawn can move forward one square, if that square is unoccupied. If it has not yet moved, each pawn has the option of moving two squares
+forward provided both squares in front of the pawn are unoccupied. A pawn cannot move backwards.
+
Pawns are the only pieces that capture differently from how they move. They can capture an enemy piece on either of the two spaces adjacent to the space in front of them (i.e., the two squares diagonally in front of them) but cannot move to these spaces if they are vacant.
+
The pawn is also involved in the two special moves en passant and promotion.
+
+
+
Castling
+
+
Castling consists of moving the king two squares towards a rook, then placing the rook on the other side of the king, adjacent to it.
+Castling is only permissible if all of the following conditions hold:
+
+
+
The king and rook involved in castling must not have previously moved;
+
There must be no pieces between the king and the rook;
+
The king may not currently be in check, nor may the king pass through or end up in a square that is under attack by an enemy piece (though the
+rook is permitted to be under attack and to pass over an attacked square);
+
+
+
+
+
+
+
+
En passant
+
+
+
+
If player A's pawn moves forward two squares and player B has a pawn on its fifth rank on an adjacent file,
+B's pawn can capture A's pawn as if A's pawn had only moved one square. This capture can only be made on the immediately
+subsequent move. In this example, if the white pawn moves from a2 to a4, the black pawn on b4 can capture it en passant, ending up on a3.
+
+
Pawn promotion
+
+
If a pawn advances to its eighth rank, it is then promoted (converted) to a queen, rook, bishop, or knight of the same color, the choice
+being at the discretion of its player (a queen is usually chosen). The choice is not limited to previously captured pieces. Hence it is
+theoretically possible for a player to have up to nine queens or up to ten rooks, bishops, or knights if all of their pawns are promoted.
+If the desired piece is not available, the player should call the arbiter to provide the piece.
+
+
Check
+
+
+
+
A king is in check when it is under attack by one or more enemy pieces. A piece unable to move because it would place its own king in check
+(it is pinned against its own king) may still deliver check to the opposing player.
+
+
A player may not make any move which places or leaves his king in check. The possible ways to get out of check are:
+
+
+
+
Move the king to a square where it is not threatened.
+
Capture the threatening piece (possibly with the king).
+
Block the check by placing a piece between the king and the opponent's threatening piece.
+
+
+
End of the game
+
+
Checkmate
+
+
+
+
If a player's king is placed in check and there is no legal move that player can make to escape check, then the king is said to be checkmated,
+the game ends, and that player loses. Unlike other pieces, the king is never actually captured or removed from the board because checkmate ends
+the game.
+
+
The diagram shows a typical checkmate position. The white king is threatened by the black queen; every square to which the king could move is
+ also threatened; it cannot capture the queen, because it would then be threatened by the rook.
+
+
Draws
+
+
+
+
The game ends in a draw if any of these conditions occur:
+
+
The game is automatically a draw if the player to move is not in check but has no legal move. This situation is called a stalemate.
+ An example of such a position is shown in the diagram to the right.
+
The game is immediately drawn when there is no possibility of checkmate for either side with any series of legal moves. This draw is
+ often due to insufficient material, including the endgames
+
+
king against king;
+
king against king and bishop;
+
king against king and knight;
+
king and bishop against king and bishop, with both bishops on diagonals of the same color.
+
+
+
Both players agree to a draw after one of the players makes such an offer.
+
+
+
The player having the move may claim a draw by declaring that one of the following conditions exists, or by declaring an intention to
+make a move which will bring about one of these conditions:
+
+
+
Fifty-move rule: There has been no capture or pawn move in the last fifty moves by each player.
+
Threefold repetition: The same board position has occurred three times with the same player to move and all pieces having the same
+rights to move, including the right to castle or capture en passant.
+
+
+
If the claim is proven true, the game is drawn.
+
+
At one time, if a player was able to check the opposing king continually (perpetual check) and the player indicated their intention to do so,
+the game was drawn. This rule is no longer in effect; however, players will usually agree to a draw in such a situation, since either the rule on
+threefold repetition or the fifty-move rule will eventually be applicable.
diff --git a/src/games/chessbase/res/rules/werewolf/werewolf-thumb.png b/src/games/chessbase/res/rules/werewolf/werewolf-thumb.png
new file mode 100644
index 00000000..17326480
Binary files /dev/null and b/src/games/chessbase/res/rules/werewolf/werewolf-thumb.png differ
diff --git a/src/games/chessbase/wild-tamerlane-credits.html b/src/games/chessbase/res/rules/wildtamerlane/wild-tamerlane-credits.html
similarity index 100%
rename from src/games/chessbase/wild-tamerlane-credits.html
rename to src/games/chessbase/res/rules/wildtamerlane/wild-tamerlane-credits.html
diff --git a/src/games/chessbase/wild-tamerlane-description.html b/src/games/chessbase/res/rules/wildtamerlane/wild-tamerlane-description.html
similarity index 100%
rename from src/games/chessbase/wild-tamerlane-description.html
rename to src/games/chessbase/res/rules/wildtamerlane/wild-tamerlane-description.html
diff --git a/src/games/chessbase/babur-rules.html b/src/games/chessbase/res/rules/wildtamerlane/wild-tamerlane-rules.html
similarity index 84%
rename from src/games/chessbase/babur-rules.html
rename to src/games/chessbase/res/rules/wildtamerlane/wild-tamerlane-rules.html
index 349e5d82..290d78b8 100644
--- a/src/games/chessbase/babur-rules.html
+++ b/src/games/chessbase/res/rules/wildtamerlane/wild-tamerlane-rules.html
@@ -12,10 +12,7 @@
float: left;
margin-right: 10px;
}
- .mi-admiral
- {
- background-image:url({GAME}/res/fairy/icons/w-admiral.png);
- }
+
.piece-icon-promo {
width: 50px;
height: 50px;
@@ -30,13 +27,16 @@
Initial setup
-
The board has 12 x 12 squares.
+
The board has 11 x 11 squares. The 11 files respect the original configuration of Tamerlane's Chess with a central King.
+ The 11 ranks give more space to the game allowing to arrange the piece before struggling. Moreover, they place Bishops
+ and Camels on same colors allowing attack of opposite counterparts and mutual protection.
-
+
-2
+
There are 28 pieces per side: 1 King, 2 Queens, 2 Gryphons, 2 Bishops, 2 Knights, 2 Rooks, 2 Elephants, 2 Camels, 2 Cannons
+ and 11 Pawns.
Pieces
@@ -121,16 +121,4 @@
Gryphon
-
-
Prince
-
-
-
-
A non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to one of the three major pieces: Queen.
The black army ('Spartans') consists, apart from the two Kings, entirely of fairy pieces, of 5 different types:
+
+
The Warlord (aka Archbishop or Cardinal): moves and captures like Knight or Bishop
+
+
+
The General (aka Crowned Rook or Dragon King): moves and captures like Rook or King
+
+
+
The Lieutenant: moves and captures 1 or 2 steps (jumping) diagonally,
+ or can step to an adjacent empty square left or right.
+
+
+
The Captain (aka Woody Rook): moves and captures 1 or 2 steps (jumping) orthogonally.
+
+
+
The Hoplit: moves 1 step diagonally forward, and captures one step straight ahead.
+ In its initial location it can also jump 2 steps diagonally forward to an empty square.
+
+
+
+
+
+
Inital setup
+
+
+
+
The white player starts with the (orthodox) Persian army, consisting of:
+
+
8 Pawns
+
2 Knights
+
2 Bishops
+
2 Rooks
+
1 Queen
+
1 King
+
+
+
+
The black player starts with the Spartan army, consisting of:
+
+
8 Hoplits
+
2 Captains
+
2 Lieutenants
+
1 General
+
1 Warlord
+
2 Kings
+
+
+
+
+
+
Castling: only the Persians can castle, in the usual way.
+
Double move for Pawns and Hoplits (start): yes, and the Hoplits jump.
+
"En passant" capture: no. The Hoplits do not really pass through Pawn attack with their jumping move,
+and for Hoplits it is geometrically impossible to have an attack on the square Pawns pass through.
+
Checking: The rules for checking are generalized to the Spartan King pair as follows:
+you are in check if you have not at least one unattacked King.
+As usual, when you have no moves that resolve that condition, you are checkmated.
+Because one King can be left attacked, it can also be captured.
+
Stalemate: when not in (generalized) check, but without legal moves, the game ends as a draw.
+
Promotion: Pawns promote as in orthodox Chess.
+Hoplits promote upon reaching the 1st rank to Spartan pieces only.
+They can also promote the King, if that will not make the number of Spartan Kings exceed two.
Chess is a game played by two people on a chessboard, with sixteen pieces (of six types) for each player. Each type of piece moves in a distinct way.
+The goal of the game is to checkmate, i.e. to threaten the opponent's king with inevitable capture. In addition, there are several ways that a game can end in a draw.
+
+
Initial setup
+
+
+
Chess is played on a chessboard, a square board divided into 64 squares (eight-by-eight) of alternating color, which is similar to that used in
+draughts (checkers). No matter what the actual colors of the board, the lighter-colored squares are called "light" or "white", and the darker-colored squares
+are called "dark" or "black". Sixteen "white" and sixteen "black" pieces are placed on the board at the beginning of the game. The board is placed so that a
+white square is in each player's near-right corner.
+
+
Each player controls sixteen pieces:
+
+
+
+
Name
Number
White Symbols
Black Symbols
+
+
+
King
+
1
+
+
+
+
+
Queen
+
1
+
+
+
+
+
Rook
+
2
+
+
+
+
+
Bishop
+
2
+
+
+
+
+
Knight
+
2
+
+
+
+
+
Pawn
+
8
+
+
+
+
+
+
At the beginning of the game, the pieces are arranged as shown in the diagram. The second row from the player contains the eight pawns;
+the row nearest the player contains the remaining pieces. Popular phrases used to remember the setup, often heard in beginners' clubs,
+are "queen on her own color" and "white on right". The latter refers to setting up the board so that the square closest to each player's right
+is white.
+
+
Play of the game
+
+
The player controlling the white army is named "White"; the player controlling the black pieces is named "Black". White moves first,
+then players alternate moves. Making a move is required; it is not legal to skip a move, even when having to move is detrimental. Play
+continues until a king is checkmated, a player resigns, or a draw is declared, as explained below. In addition, if the game is being played
+under a time control players who exceed their time limit lose the game.
+
+
Movement
+
+
Basic moves
+
+
Each chess piece has its own method of movement. Moves are made to vacant squares except when capturing an opponent's piece.
+
+
With the exception of any movement of the knight and the occasional castling maneuver, pieces cannot jump over each other. When a piece is
+captured (or taken), the attacking piece replaces the enemy piece on its square (en passant being the only exception). The captured piece is
+thus removed from the game and may not be returned to play for the remainder of the game. The king can be put in check but cannot be
+captured (see below).
+
+
+
King
+
+
The king can move exactly one square horizontally, vertically, or diagonally. Only once per player, per game, is a king allowed to make a
+ special move known as castling (see below).
+
+
+
Rooks
+
+
The rook moves any number of vacant squares vertically or horizontally. It also is moved while castling.
+
+
+
Bishops
+
+
The bishop moves any number of vacant squares in any diagonal direction.
+
+
+
Queen
+
+
The queen can move any number of vacant squares diagonally, horizontally, or vertically.
+
+
+
Knights
+
+
The knight moves to the nearest square not on the same rank, file, or diagonal. In other words, the knight moves
+two squares horizontally then one square vertically, or one square horizontally then two squares vertically. Its move is not
+blocked by other pieces: it jumps to the new location.
+
+
+
Pawns
+
+
Pawns have the most complex rules of movement:
+
+
A pawn can move forward one square, if that square is unoccupied. If it has not yet moved, each pawn has the option of moving two squares
+forward provided both squares in front of the pawn are unoccupied. A pawn cannot move backwards.
+
Pawns are the only pieces that capture differently from how they move. They can capture an enemy piece on either of the two spaces adjacent to the space in front of them (i.e., the two squares diagonally in front of them) but cannot move to these spaces if they are vacant.
+
The pawn is also involved in the two special moves en passant and promotion.
+
+
+
Castling
+
+
Castling consists of moving the king two squares towards a rook, then placing the rook on the other side of the king, adjacent to it.
+Castling is only permissible if all of the following conditions hold:
+
+
+
The king and rook involved in castling must not have previously moved;
+
There must be no pieces between the king and the rook;
+
The king may not currently be in check, nor may the king pass through or end up in a square that is under attack by an enemy piece (though the
+rook is permitted to be under attack and to pass over an attacked square);
+
+
+
+
+
+
+
+
En passant
+
+
+
+
If player A's pawn moves forward two squares and player B has a pawn on its fifth rank on an adjacent file,
+B's pawn can capture A's pawn as if A's pawn had only moved one square. This capture can only be made on the immediately
+subsequent move. In this example, if the white pawn moves from a2 to a4, the black pawn on b4 can capture it en passant, ending up on a3.
+
+
Pawn promotion
+
+
If a pawn advances to its eighth rank, it is then promoted (converted) to a queen, rook, bishop, or knight of the same color, the choice
+being at the discretion of its player (a queen is usually chosen). The choice is not limited to previously captured pieces. Hence it is
+theoretically possible for a player to have up to nine queens or up to ten rooks, bishops, or knights if all of their pawns are promoted.
+If the desired piece is not available, the player should call the arbiter to provide the piece.
+
+
Check
+
+
+
+
A king is in check when it is under attack by one or more enemy pieces. A piece unable to move because it would place its own king in check
+(it is pinned against its own king) may still deliver check to the opposing player.
+
+
A player may not make any move which places or leaves his king in check. The possible ways to get out of check are:
+
+
+
+
Move the king to a square where it is not threatened.
+
Capture the threatening piece (possibly with the king).
+
Block the check by placing a piece between the king and the opponent's threatening piece.
+
+
+
End of the game
+
+
Checkmate
+
+
+
+
If a player's king is placed in check and there is no legal move that player can make to escape check, then the king is said to be checkmated,
+the game ends, and that player loses. Unlike other pieces, the king is never actually captured or removed from the board because checkmate ends
+the game.
+
+
The diagram shows a typical checkmate position. The white king is threatened by the black queen; every square to which the king could move is
+ also threatened; it cannot capture the queen, because it would then be threatened by the rook.
+
+
Draws
+
+
+
+
The game ends in a draw if any of these conditions occur:
+
+
The game is automatically a draw if the player to move is not in check but has no legal move. This situation is called a stalemate.
+ An example of such a position is shown in the diagram to the right.
+
The game is immediately drawn when there is no possibility of checkmate for either side with any series of legal moves. This draw is
+ often due to insufficient material, including the endgames
+
+
king against king;
+
king against king and bishop;
+
king against king and knight;
+
king and bishop against king and bishop, with both bishops on diagonals of the same color.
+
+
+
Both players agree to a draw after one of the players makes such an offer.
+
+
+
The player having the move may claim a draw by declaring that one of the following conditions exists, or by declaring an intention to
+make a move which will bring about one of these conditions:
+
+
+
Fifty-move rule: There has been no capture or pawn move in the last fifty moves by each player.
+
Threefold repetition: The same board position has occurred three times with the same player to move and all pieces having the same
+rights to move, including the right to castle or capture en passant.
+
+
+
If the claim is proven true, the game is drawn.
+
+
At one time, if a player was able to check the opposing king continually (perpetual check) and the player indicated their intention to do so,
+the game was drawn. This rule is no longer in effect; however, players will usually agree to a draw in such a situation, since either the rule on
+threefold repetition or the fifty-move rule will eventually be applicable.
diff --git a/src/games/chessbase/timurid-model.js b/src/games/chessbase/timurid-model.js
deleted file mode 100644
index 78570b6f..00000000
--- a/src/games/chessbase/timurid-model.js
+++ /dev/null
@@ -1,291 +0,0 @@
-/*
- * Copyright(c) 2013-2014 - jocly.com
- *
- * You are allowed to use and modify this source code as long as it is exclusively for use in the Jocly API.
- *
- * Original authors: Jocly team
- *
- */
-(function() {
-
- var firstRow=0;
- var lastRow=11;
- var firstCol=0;
- var lastCol=11;
-
- var geometry = Model.Game.cbBoardGeometryGrid(12,12);
-
- // graphs
-
- Model.Game.cbPrinceGraph = function(geometry,side,confine) {
- var $this=this;
- var graph={};
- for(var pos=0;pos0)
- graph[pos].push($this.cbTypedArray(away));
- }
- }
- });
- }
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[-1,-1],[-1,1],[1,-1],[1,1]]),
- graph
- );
- }
-
- Model.Game.cbShipGraph = function(geometry){
- var $this=this;
-
- var flags = $this.cbConstants.FLAG_MOVE | $this.cbConstants.FLAG_CAPTURE;
- var graph={};
- for(var pos=0;pos0)
- graph[pos].push($this.cbTypedArray(away));
- }
- }
- });
- }
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[-1,-1],[-1,1],[1,-1],[1,1]]),
- graph
- );
- }
-
- var confine = {};
-
- for(var pos=0;pos 0) || (geometry.R(move.t)==firstRow && piece.s < 0)) )
- return [T_eagle];
- return [];
- },
- };
- }
-
-})();
diff --git a/src/games/chessbase/timurid-rules.html b/src/games/chessbase/timurid-rules.html
deleted file mode 100644
index 8d23e617..00000000
--- a/src/games/chessbase/timurid-rules.html
+++ /dev/null
@@ -1,128 +0,0 @@
-
-
-
Initial setup
-
-
-
The board has 12 x 12 squares.
-
-
-
-
-
-2
-
-
-
Pieces
-
-
King
-
-
-
-
Moves as in usual Chess, except there is no castling.
-
-
-
-
-
Queen
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Bishop
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Knight
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Rook
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Elephant
-
-
-
-
Moves one or two squares diagonally. When an Elephant moves two squares, it is allowed to jump, i.e., the intervening square does not have to be empty. The Elephant moves as the combined Alfil and Firzan (Ferz) from Shatranj, two pieces which were also present in mediaeval Chess and have disappeared with the birth of modern moves for Queen and Bishop.
-
-
-
-
-
Camel
-
-
-
-
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square.
-
-
-
-
-
Cannon
-
-
-
-
moves without taking like a Rook, but it takes by going in a straight horizontal and vertical line and jumping over exactly one piece. When a Cannon takes a piece, there must be exactly one piece between the original and final square of the Cannon's move - this piece may be of either color. (This is identical to the move of the Cannon in Xiangqi.)
-
-
-
-
-
Gryphon
-
-
-
-
Moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex. In my other more recent chess variants, this piece is called an Eagle.
-
-
-
-
-Prince: a non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to one of the three major pieces: Queen, Lion or Eagle.
-
-
-
diff --git a/src/games/chessbase/timurid-thumb.png b/src/games/chessbase/timurid-thumb.png
deleted file mode 100644
index 2e5fb391..00000000
Binary files a/src/games/chessbase/timurid-thumb.png and /dev/null differ
diff --git a/src/games/chessbase/kaisergame-model.js b/src/games/chessbase/tressau/kaisergame-model.js
similarity index 100%
rename from src/games/chessbase/kaisergame-model.js
rename to src/games/chessbase/tressau/kaisergame-model.js
diff --git a/src/games/chessbase/sultangame-model.js b/src/games/chessbase/tressau/sultangame-model.js
similarity index 100%
rename from src/games/chessbase/sultangame-model.js
rename to src/games/chessbase/tressau/sultangame-model.js
diff --git a/src/games/chessbase/sultangame-view.js b/src/games/chessbase/tressau/sultangame-view.js
similarity index 100%
rename from src/games/chessbase/sultangame-view.js
rename to src/games/chessbase/tressau/sultangame-view.js
diff --git a/src/games/chessbase/werewolf-model.js b/src/games/chessbase/werewolf-model.js
new file mode 100644
index 00000000..dae53de9
--- /dev/null
+++ b/src/games/chessbase/werewolf-model.js
@@ -0,0 +1,143 @@
+
+(function() {
+
+ var geometry = Model.Game.cbBoardGeometryGrid(8,8);
+
+ Model.Game.cbDefine = function() {
+
+ var wolf = this.cbConstants.FLAG_SPECIAL | this.cbConstants.FLAG_SPECIAL_CAPTURE | this.cbConstants.FLAG_THREAT; // wolf-mode flags
+
+ var p = this.cbPiecesFromFEN(geometry, 'rnb1kbnr/pppppppp/8/8/8/8/PPPPPPPP/RNB1KBNR');
+
+ var ww = p.addPiece({
+ name: 'werewolf',
+ aspect: 'fr-wolf',
+ graph: this.cbMergeGraphs(geometry,
+ this.cbLongRangeGraph(geometry,
+ [[1,0],[0,1],[-1,0],[0,-1],[1,1],[1,-1],[-1,1],[-1,-1]],null,null,3),
+ this.cbShortRangeGraph(geometry,
+ [[2,0],[0,2],[-2,0],[0,-2],[2,2],[2,-2],[-2,2],[-2,-2]],null,wolf)
+ ),
+ value: 10,
+ abbrev: 'W',
+ initial: [{s:1,p:3},{s:-1,p:59}],
+ });
+
+ return {
+
+ geometry: geometry,
+
+ pieceTypes: p.pieceTypes,
+
+ promote: function(aGame,piece,move) {
+ if(move.c !== null && this.pieces[move.c].t == ww // captured Werewolf
+ && move.a != 'W' && move.a != 'K') // by non-Werewolf other than King
+ return [ww]; // so promote to one
+ else if(piece.t==0 && geometry.R(move.t)==7)
+ return [4,2,3];
+ else if(piece.t==1 && geometry.R(move.t)==0)
+ return [4,2,3];
+ return [];
+ },
+
+ castle: p.castle,
+
+ evaluate: function(aGame,evalValues,material,pieceCount) {
+ // check lack of material to checkmate
+ var white=material[1].count;
+ var black=material[-1].count;
+ if(pieceCount[1]==1) { // white king single
+ if(!black[2] && !black[3] && !black[6] && !black[7] && (black[4]+black[5]<2 || black[5]<2)) {
+ this.mFinished=true;
+ this.mWinner=JocGame.DRAW;
+ }
+ }
+ if(pieceCount[-1]==1) { // black king single
+ if(!white[0] && !white[1] && !white[6] && !white[7] && (white[4]+white[5]<2 || white[5]<2)) {
+ this.mFinished=true;
+ this.mWinner=JocGame.DRAW;
+ }
+ }
+
+ // check 50 moves without capture
+ if(this.noCaptCount>=100) {
+ this.mFinished=true;
+ this.mWinner=JocGame.DRAW;
+ }
+
+ // Bishop pair (penalize single Bishop)
+ if(white[5]==1) evalValues.pieceValue-=0.25;
+ if(black[5]==1) evalValues.pieceValue+=0.25;
+
+ // motivate pawns to reach the promotion line
+ var distPromo=aGame.cbUseTypedArrays?new Int8Array(3):[0,0,0];
+ var height=geometry.height;
+ var pawns=material[1].byType[0],pawnsLength;
+ if(pawns) {
+ pawnsLength=pawns.length;
+ for(var i=0;i=-1;s-=2) {
+ var pieces=material[s].byType[t];
+ if(pieces)
+ for(var i=0;i> 1; // jumped-over square
+ var victim = aBoard.board[mid];
+
+ if(victim < 0) return; // slide did already reach move.t
+
+ moves.push({ // reach target through jump
+ f: move.f,
+ t: move.t,
+ c: move.c,
+ a: move.a
+ });
+
+ if(aBoard.pieces[victim].s != aBoard.mWho) // jumped over foe
+ moves.push({ // also try to capture it
+ f: move.f,
+ t: move.t,
+ c: move.c,
+ via: mid,
+ kill: victim,
+ a: move.a
+ });
+ }
+})();
diff --git a/src/games/chessbase/werewolf-view.js b/src/games/chessbase/werewolf-view.js
new file mode 100644
index 00000000..35ca5a78
--- /dev/null
+++ b/src/games/chessbase/werewolf-view.js
@@ -0,0 +1,61 @@
+(function() {
+
+ View.Game.cbDefineView = function() {
+
+ return {
+ coords: {
+ "2d": this.cbGridBoard.coordsFn.call(this,this.cbGridBoardClassic2DMargin),
+ "3d": this.cbGridBoard.coordsFn.call(this,this.cbGridBoardClassic3DMargin),
+ },
+ boardLayout: [
+ ".#.#.#.#",
+ "#.#.#.#.",
+ ".#.#.#.#",
+ "#.#.#.#.",
+ ".#.#.#.#",
+ "#.#.#.#.",
+ ".#.#.#.#",
+ "#.#.#.#.",
+ ],
+ board: {
+ "2d": {
+ draw: this.cbDrawBoardFn(this.cbGridBoardClassic2DMargin),
+ },
+ "3d": {
+ display: this.cbDisplayBoardFn(this.cbGridBoardClassic3DMargin),
+ },
+ },
+ clicker: {
+ "2d": {
+ width: 1300,
+ height: 1300,
+ },
+ "3d": {
+ scale: [.9,.9,.9],
+ },
+ },
+ pieces: this.cbFairyPieceStyle({
+ "default": {
+ "2d": {
+ width: 1200,
+ height: 1200,
+ },
+ "3d": {
+ scale: [.6,.6,.6],
+ },
+ },
+ }),
+ };
+ }
+
+ /* Make the knight jump when moving */
+ View.Board.cbMoveMidZ = function(aGame,aMove,zFrom,zTo) {
+ var d = aMove.t - aMove.f;
+ if(aMove.a=='N' ||
+ aMove.a=='W' && aMove.via === undefined && !(d&1) && (d&15)!=8 )
+ return Math.max(zFrom,zTo)+1500;
+ else
+ return (zFrom+zTo)/2;
+ }
+
+})();
diff --git a/src/games/chessbase/wild-babur-credits.html b/src/games/chessbase/wild-babur-credits.html
deleted file mode 100644
index 5a39b30d..00000000
--- a/src/games/chessbase/wild-babur-credits.html
+++ /dev/null
@@ -1,6 +0,0 @@
-
Moves as in usual Chess, except there is no castling.
-
-
-
-
-
Queen
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Bishop
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Knight
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Rook
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Elephant
-
-
-
-
Moves one or two squares diagonally. When an Elephant moves two squares, it is allowed to jump, i.e., the intervening square does not have to be empty. The Elephant moves as the combined Alfil and Firzan (Ferz) from Shatranj, two pieces which were also present in mediaeval Chess and have disappeared with the birth of modern moves for Queen and Bishop.
-
-
-
-
-
Camel
-
-
-
-
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square.
-
-
-
-
-
Cannon
-
-
-
-
moves without taking like a Rook, but it takes by going in a straight horizontal and vertical line and jumping over exactly one piece. When a Cannon takes a piece, there must be exactly one piece between the original and final square of the Cannon's move - this piece may be of either color. (This is identical to the move of the Cannon in Xiangqi.)
-
-
-
-
-
Gryphon
-
-
-
-
Moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex. In my other more recent chess variants, this piece is called an Eagle.
-
-
-
-
-
Lion
-
-
-
-
It jumps on any square situated at 1 or 2 squares distance from where it stands.
-
-
-
-
-
-
Prince
-
-
-
-
A non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to one of the three major pieces: Queen.
diff --git a/src/games/chessbase/wild-mirza-model.js b/src/games/chessbase/wild-mirza-model.js
deleted file mode 100644
index 5bb9ddb0..00000000
--- a/src/games/chessbase/wild-mirza-model.js
+++ /dev/null
@@ -1,461 +0,0 @@
-/*
- * Copyright(c) 2013-2014 - jocly.com
- *
- * You are allowed to use and modify this source code as long as it is exclusively for use in the Jocly API.
- *
- * Original authors: Jocly team
- *
- */
-(function() {
-
- var firstRow=0;
- var lastRow=11;
- var firstCol=0;
- var lastCol=11;
-
- var geometry = Model.Game.cbBoardGeometryGrid(12,12);
-
- // graphs
-
- Model.Game.cbSnakeGraph = function(geometry,confine){
- var $this=this;
-
- var flags = $this.cbConstants.FLAG_MOVE | $this.cbConstants.FLAG_CAPTURE;
- var graph={};
- for(var pos=0;pos0)
- directions.push($this.cbTypedArray(awayl));
- if(awayr.length>0)
- directions.push($this.cbTypedArray(awayr));
- }
- });
- graph[pos]=directions;
-
- }
-
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[0,1],[0,-1]]),
- graph
- );
- }
-
- Model.Game.cbRhinoGraph = function(geometry,confine){
- var $this=this;
-
- var flags = $this.cbConstants.FLAG_MOVE | $this.cbConstants.FLAG_CAPTURE;
- var graph={};
- for(var pos=0;pos0)
- directions.push($this.cbTypedArray(awayl));
- if(awayr.length>0)
- directions.push($this.cbTypedArray(awayr));
- }
- });
- graph[pos]=directions;
-
- }
-
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[0,1],[1,0],[-1,0],[0,-1]]),
- graph
- );
- }
-
- Model.Game.cbPrinceGraph = function(geometry,side,confine) {
- var $this=this;
- var graph={};
- for(var pos=0;pos0)
- graph[pos].push($this.cbTypedArray(away));
- }
- }
- });
- }
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[-1,-1],[-1,1],[1,-1],[1,1]]),
- graph
- );
- }
-
- Model.Game.cbShipGraph = function(geometry){
- var $this=this;
-
- var flags = $this.cbConstants.FLAG_MOVE | $this.cbConstants.FLAG_CAPTURE;
- var graph={};
- for(var pos=0;pos0)
- graph[pos].push($this.cbTypedArray(away));
- }
- }
- });
- }
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[-1,-1],[-1,1],[1,-1],[1,1]]),
- graph
- );
- }
-
- var confine = {};
-
- for(var pos=0;pos 0) || (geometry.R(move.t)==firstRow && piece.s < 0)) )
- return [T_rhino];
- if (piece.t==T_ship && ((geometry.R(move.t)==lastRow && piece.s > 0) || (geometry.R(move.t)==firstRow && piece.s < 0)) )
- return [T_eagle];
- return [];
- },
- };
- }
-
-})();
diff --git a/src/games/chessbase/wild-mirza-rules.html b/src/games/chessbase/wild-mirza-rules.html
deleted file mode 100644
index 95b5435b..00000000
--- a/src/games/chessbase/wild-mirza-rules.html
+++ /dev/null
@@ -1,145 +0,0 @@
-
-
-
Initial setup
-
-
-
The board has 12 x 12 squares.
-
-
-
-
-
-2
-
-
-
Pieces
-
-
King
-
-
-
-
Moves as in usual Chess, except there is no castling.
-
-
-
-
-
Queen
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Bishop
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Knight
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Rook
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Elephant
-
-
-
-
Moves one or two squares diagonally. When an Elephant moves two squares, it is allowed to jump, i.e., the intervening square does not have to be empty. The Elephant moves as the combined Alfil and Firzan (Ferz) from Shatranj, two pieces which were also present in mediaeval Chess and have disappeared with the birth of modern moves for Queen and Bishop.
-
-
-
-
-
Camel
-
-
-
-
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square.
-
-
-
-
-
Cannon
-
-
-
-
moves without taking like a Rook, but it takes by going in a straight horizontal and vertical line and jumping over exactly one piece. When a Cannon takes a piece, there must be exactly one piece between the original and final square of the Cannon's move - this piece may be of either color. (This is identical to the move of the Cannon in Xiangqi.)
-
-
-
-
-
Gryphon
-
-
-
-
Moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex. In my other more recent chess variants, this piece is called an Eagle.
-
-
-
-
-
Snake
-
-
-
-
Moves one square vertically and then, slides away of an indefinite number of squares diagonally.
-
-
-
-
-
Prince
-
-
-
-
A non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to one of the three major pieces: Queen.
The fact that strong pieces can only appear after promotion gives an original taste to this large Chess Variant but can appear
- as too slow to some modern players. Those looking for strategies around "bloody" battles, may appreciate a simple this variant
- where Ship are replaced by Eagles (i.e. Gryphons) from the initial set-up.
diff --git a/src/games/chessbase/wild-timurid-model.js b/src/games/chessbase/wild-timurid-model.js
deleted file mode 100644
index bd8db3af..00000000
--- a/src/games/chessbase/wild-timurid-model.js
+++ /dev/null
@@ -1,284 +0,0 @@
-/*
- * Copyright(c) 2013-2014 - jocly.com
- *
- * You are allowed to use and modify this source code as long as it is exclusively for use in the Jocly API.
- *
- * Original authors: Jocly team
- *
- */
-(function() {
-
- var firstRow=0;
- var lastRow=11;
- var firstCol=0;
- var lastCol=11;
-
- var geometry = Model.Game.cbBoardGeometryGrid(12,12);
-
- // graphs
-
- Model.Game.cbPrinceGraph = function(geometry,side,confine) {
- var $this=this;
- var graph={};
- for(var pos=0;pos0)
- graph[pos].push($this.cbTypedArray(away));
- }
- }
- });
- }
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[-1,-1],[-1,1],[1,-1],[1,1]]),
- graph
- );
- }
-
- /*Model.Game.cbShipGraph = function(geometry){
- var $this=this;
-
- var flags = $this.cbConstants.FLAG_MOVE | $this.cbConstants.FLAG_CAPTURE;
- var graph={};
- for(var pos=0;pos0)
- graph[pos].push($this.cbTypedArray(away));
- }
- }
- });
- }
- return $this.cbMergeGraphs(geometry,
- $this.cbShortRangeGraph(geometry,[[-1,-1],[-1,1],[1,-1],[1,1]]),
- graph
- );
- }*/
-
- var confine = {};
-
- for(var pos=0;pos 0) || (geometry.R(move.t)==firstRow && piece.s < 0)) )
- return [T_eagle];
- return [];
- },
- };
- }
-
-})();
diff --git a/src/games/chessbase/wild-timurid-rules.html b/src/games/chessbase/wild-timurid-rules.html
deleted file mode 100644
index a4d1adf5..00000000
--- a/src/games/chessbase/wild-timurid-rules.html
+++ /dev/null
@@ -1,134 +0,0 @@
-
-
-
Initial setup
-
-
-
The board has 12 x 12 squares.
-
-
-
-
-
-
-
Pieces
-
-
King
-
-
-
-
Moves as in usual Chess, except there is no castling.
-
-
-
-
-
Queen
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Bishop
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Knight
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Rook
-
-
-
-
Exactly as in usual Chess.
-
-
-
-
-
Elephant
-
-
-
-
Moves one or two squares diagonally. When an Elephant moves two squares, it is allowed to jump, i.e., the intervening square does not have to be empty. The Elephant moves as the combined Alfil and Firzan (Ferz) from Shatranj, two pieces which were also present in mediaeval Chess and have disappeared with the birth of modern moves for Queen and Bishop.
-
-
-
-
-
Camel
-
-
-
-
As in Metamachy, a well known piece from medieval Muslim great Chess like Tamerlane's Chess. It jumps to the opposite case of a 2x4 rectangle, like an extended Knight. No matter what intermediate cases contain. Note that it always stays on the same color of square.
-
-
-
-
-
Cannon
-
-
-
-
moves without taking like a Rook, but it takes by going in a straight horizontal and vertical line and jumping over exactly one piece. When a Cannon takes a piece, there must be exactly one piece between the original and final square of the Cannon's move - this piece may be of either color. (This is identical to the move of the Cannon in Xiangqi.)
-
-
-
-
-
Gryphon
-
-
-
-
Moves one square diagonally and then, goes away of an indefinite number of cases vertically or horizontally. It is authorized to go only one square diagonal. It can not jump and the unobstructed path must start with the diagonal movement. This piece is almost as powerful as the Queen and is inspired by the Giraffe from Tamerlane's Chess and the Aanca from Alfonso X's Grande Acedrex. In my other more recent chess variants, this piece is called an Eagle.
-
-
-
-
-
Prince
-
-
-
-
A non-royal King who moves and captures one square in any direction, but without being hindered by check. Like the Pawn, he can also move without capturing to the second square straight ahead. When he reaches the last row it can promote to one of the three major pieces: Queen.
-
-
-
-
-
-
-
diff --git a/src/games/chessbase/wild-timurid-thumb.png b/src/games/chessbase/wild-timurid-thumb.png
deleted file mode 100644
index 69fb5d71..00000000
Binary files a/src/games/chessbase/wild-timurid-thumb.png and /dev/null differ
diff --git a/src/games/chessbase/wildebeest-model.js b/src/games/chessbase/wildebeest-model.js
index 8f7ef315..aeb61397 100644
--- a/src/games/chessbase/wildebeest-model.js
+++ b/src/games/chessbase/wildebeest-model.js
@@ -19,6 +19,7 @@
);
}
+ Model.Game.cbOnStaleMate = -1; // stalemate = last player wins
Model.Game.cbDefine = function() {
@@ -176,153 +177,13 @@
},
castle: {
- "5/0": {k:[4],r:[1,2,3,4,5],n:"O-O-O"},
- "5/10": {k:[6],r:[9,8,7,6,5],n:"O-O"},
- "104/99": {k:[103],r:[100,101,102,103,104],n:"O-O-O"},
- "104/109": {k:[105],r:[108,107,106,105,104],n:"O-O"},
+ "5/0": {k:[4],r:[1,2,3,4,5],n:"O-O-O",extra:3},
+ "5/10": {k:[6],r:[9,8,7,6,5],n:"O-O",extra:3},
+ "104/99": {k:[103],r:[100,101,102,103,104],n:"O-O-O",extra:3},
+ "104/109": {k:[105],r:[108,107,106,105,104],n:"O-O",extra:3},
},
};
}
-
- var extraCastle={0:{k:[3,2,1],r:[4,3,2]},10:{k:[7,8,9],r:[6,7,8]},
- 99:{k:[102,101,100],r:[103,102,101]},109:{k:[106,107,108],r:[105,106,107]}
- }
-
- var SuperModelBoardGenerateMoves=Model.Board.GenerateMoves;
- Model.Board.GenerateMoves = function(aGame) {
- SuperModelBoardGenerateMoves.apply(this,arguments); // call regular GenerateMoves method
- if(!this.castled[this.mWho]) {
- for(var i=0;i0;
- if(!inCheck) {
- var rIndex=this.board[move.cg];
- var rPiece=this.pieces[rIndex];
- this.board[move.cg]=-1;
- this.board[extra.r[0]]=rIndex;
- rPiece.p=extra.r[0];
-
- var oppInCheck=this.cbGetAttackers(aGame,this.kings[-this.mWho],-this.mWho,true).length>0;
- this.mMoves.push({
- f: move.f,
- t: extra.k[0],
- c: null,
- ck: oppInCheck,
- a: 'K',
- });
-
- this.board[move.f]=kIndex;
- this.board[extra.k[0]]=-1;
- this.board[move.cg]=rIndex;
- this.board[extra.r[0]]=-1;
-
- this.board[move.f]=-1;
- this.board[extra.k[1]]=kIndex;
- kPiece.p=extra.k[1];
-
- inCheck=this.cbGetAttackers(aGame,kPiece.p,this.mWho,true).length>0;
- if(!inCheck) {
- this.board[move.cg]=-1;
- this.board[extra.r[1]]=rIndex;
- rPiece.p=extra.r[1];
-
- oppInCheck=this.cbGetAttackers(aGame,this.kings[-this.mWho],-this.mWho,true).length>0;
- this.mMoves.push({
- f: move.f,
- t: extra.k[1],
- c: null,
- ck: oppInCheck,
- a: 'K',
- });
-
- /*---*/
-
- this.board[move.f]=-1;
- this.board[extra.k[2]]=kIndex;
- kPiece.p=extra.k[2];
-
- inCheck=this.cbGetAttackers(aGame,kPiece.p,this.mWho,true).length>0;
- if(!inCheck) {
- this.board[move.cg]=-1;
- this.board[extra.r[2]]=rIndex;
- rPiece.p=extra.r[2];
-
- oppInCheck=this.cbGetAttackers(aGame,this.kings[-this.mWho],-this.mWho,true).length>0;
- this.mMoves.push({
- f: move.f,
- t: extra.k[2],
- c: null,
- ck: oppInCheck,
- a: 'K',
- });
-
- this.board[move.cg]=rIndex;
- this.board[extra.r[2]]=-1;
- }
-
- this.board[move.f]=kIndex;
- this.board[extra.k[2]]=-1;
-
- /*---*/
-
- this.board[move.cg]=rIndex;
- this.board[extra.r[1]]=-1;
- }
- this.board[move.f]=kIndex;
- this.board[extra.k[1]]=-1;
-
- this.board[move.cg]=rIndex;
- rPiece.p=move.cg;
- }
- this.board[move.f]=kIndex;
- kPiece.p=move.f;
- }
- }
- }
- }
-
- Model.Game.wbExtraCastleRook={ // rook identification and displacement from king destination
- 1:{r0:0,r:2},2:{r0:0,r:3},3:{r0:0,r:4},
- 7:{r0:10,r:6},8:{r0:10,r:7},9:{r0:10,r:8},
- 100:{r0:99,r:101},101:{r0:99,r:102},102:{r0:99,r:103},
- 105:{r0:109,r:104},106:{r0:109,r:105},107:{r0:109,r:106}
- }
-
- var SuperModelBoardApplyMove=Model.Board.ApplyMove;
- Model.Board.ApplyMove = function(aGame,move) {
- if(move.a=='K' && !this.castled[this.mWho] && move.cg===undefined) {
- var dc=Math.abs(geometry.C(move.t)-geometry.C(move.f));
- if(dc>=2) {
- var kPiece=this.pieces[this.board[move.f]];
- this.board[move.f]=-1;
- this.zSign=aGame.zobrist.update(this.zSign,"board",kPiece.i,move.f);
- this.board[move.t]=kPiece.i;
- this.zSign=aGame.zobrist.update(this.zSign,"board",kPiece.i,move.t);
- kPiece.p=move.t;
- this.kings[this.mWho]=kPiece.p;
- var extra=aGame.wbExtraCastleRook[move.t];
- var rPiece=this.pieces[this.board[extra.r0]];
- this.board[extra.r0]=-1;
- this.zSign=aGame.zobrist.update(this.zSign,"board",rPiece.i,extra.r0);
- this.board[extra.r]=rPiece.i;
- this.zSign=aGame.zobrist.update(this.zSign,"board",rPiece.i,extra.r);
- rPiece.p=extra.r;
- this.check=!!move.ck;
- this.castled[this.mWho]=true;
- return;
- }
- }
- SuperModelBoardApplyMove.apply(this,arguments);
- }
-
-})();
\ No newline at end of file
+})();
diff --git a/src/games/chessbase/wildebeest-view.js b/src/games/chessbase/wildebeest-view.js
index 6b100b2d..f061ec49 100644
--- a/src/games/chessbase/wildebeest-view.js
+++ b/src/games/chessbase/wildebeest-view.js
@@ -25,7 +25,7 @@
"3d": this.cbGridBoard.coordsFn.call(this,wildebeestBoard3d),
},
boardLayout: [
- "#.#.#.#.#.#",
+ "#.#.#.#.#.#",
".#.#.#.#.#.",
"#.#.#.#.#.#",
".#.#.#.#.#.",
@@ -34,7 +34,7 @@
"#.#.#.#.#.#",
".#.#.#.#.#.",
"#.#.#.#.#.#",
- ".#.#.#.#.#.",
+ ".#.#.#.#.#.",
],
board: {
"2d": {
@@ -63,46 +63,4 @@
};
}
- /* Make the knight, camel and wildebeest jump when leaping */
- View.Board.cbMoveMidZ = function(aGame,aMove,zFrom,zTo) {
- var geometry = aGame.cbVar.geometry;
- var x0 = geometry.C(aMove.f);
- var x1 = geometry.C(aMove.t);
- var y0 = geometry.R(aMove.f);
- var y1 = geometry.R(aMove.t);
- if(x1-x0==0 || y1-y0==0 || Math.abs(x1-x0)==Math.abs(y1-y0))
- return (zFrom+zTo)/2;
- else
- return Math.max(zFrom,zTo)+1500;
- }
-
- var SuperViewBoardcbAnimate = View.Board.cbAnimate;
- View.Board.cbAnimate = function(xdv,aGame,aMove,callback) {
-
- var piece=this.pieces[this.board[aMove.f]];
- if(piece.t==8 && !this.castled[this.mWho] && aMove.cg===undefined) {
- var geometry = aGame.cbVar.geometry;
- var dc=Math.abs(geometry.C(aMove.t)-geometry.C(aMove.f));
- if(dc>=2) {
- var extra=aGame.wbExtraCastleRook[aMove.t];
- var rPiece=this.pieces[this.board[extra.r0]];
-
- var animCount=2;
- function EndAnim() {
- if(--animCount==0)
- callback();
- }
- SuperViewBoardcbAnimate.call(this,xdv,aGame,aMove,function() {
- EndAnim();
- });
- var displaySpec=aGame.cbMakeDisplaySpecForPiece(aGame,extra.r,rPiece);
- xdv.updateGadget("piece#"+rPiece.i,displaySpec,600,function() {
- EndAnim();
- });
- return;
- }
- }
- SuperViewBoardcbAnimate.apply(this,arguments);
- }
-
})();
diff --git a/tube/README.txt b/tube/README.txt
new file mode 100644
index 00000000..42de5bd1
--- /dev/null
+++ b/tube/README.txt
@@ -0,0 +1,355 @@
+'tube' is a command-line tool for facilitating creation of
+3d pieces for Jocly, for those that don't want to use fancy
+design programs like Blender. It can be compiled with the
+command 'gcc tube.c -o tube -lm'.
+
+Basics
+
+A Jocly 3d image for piece xxx consists of three files: xxx.js,
+xxx-diffusemap.jpg and xxx-normalmap.jpg. The .js file contains
+the 'mesh': lists of point coordinates that define the 3d shape
+('vertices'), lists of coordinates of points in the map files
+to cut out part of these and paint it on the surface of the 3d
+object ('uvs'), and a list of vertex and uv numbers to indicate
+how these points are connected to form triangles and quadrangles
+('faces').
+ The diffusemap is an image file in true colors, which will be
+used to paint the faces of the 3d object as specified by the
+uvs. Jocly might manipulate the colors, e.g. to create black
+versions of the piece, and account for light/shadow effects.
+ The normalmap is an image that controls the direction of
+reflections relative to the surface, encoded in false colors.
+This is used to create the illusion of height variations on
+faces that are really flat. The neutral color is light blue,
+for indicating a flat surface. But Jocly manipulates this
+such that adjacent faces that do not make an acute angle
+appear curved such that they seemlessly fit together.
+This way the Pawns head, which in vertical cross section is
+just a hexagon, reflects light as if it is a perfect sphere.
+
+The Tube tool creates 3d objects as a sequence of 'rings',
+with equal number of points along their circumference.
+Corresponding points of adjacent rings are connected to
+form quadrangular faces, to make a (cylindrical or conical)
+tube 'section'. The entire series of rings thus defines a
+tube of variable diameter.
+ The lower and left 81% of the map files (which always are
+512x512 images) represent this tube surface, and wraps
+around such that left and right edges connect. A red/green
+scale to the right of this area in the diffusemap indicates
+which part of the map corresponds to which tube section.
+This can be useful when you want to edit the image (e.g.
+with Gimp or MS Paint) for painting details on it.
+
+One of the sections can be a cone, where a single point
+(the top) connects to all points of the preceding ring,
+to form triangular faces. A disk in the upper right of the
+maps is used to color this cone. This facility is mainly
+offered in case you want to paint something on a nearly
+flat top, which would be highly distorted if you would
+have described it as a tube section with one of the ends
+invisibly narrow.
+
+Design cycle
+
+The Tube tool takes its input from a file specified in
+the command line, e.g.
+
+tube piece.dat
+
+Running this would create the .js file, and both maps
+in .bmp (Windows bitmap) format. The latter then have
+to be converted to .jpg by commands like
+
+convert piece-normalmap.bmp piece-normalmap.jpg
+
+on Linux. (On Windows I would know no other way to do it
+than loading the .bmp in MS Paint, and then saving again
+in .jpg format.)
+
+We can then copy the .js and .jpg files to the directory
+of a piece in the Jocly library, e.g. to
+
+jocly/dist/browser/games/chessbase/res/staunton/rook/
+
+calling them rook.js etc., overwriting the original rook.
+(It would be easiest to put these commands for conversion
+and copying into a shell script, as you will run the
+combination of commands many times.) This replaces the 3d
+rook image by your piece. By letting Jocly then run normal
+Chess you would then see that piece appear on the corner
+squares, where you can examine it in close up to see how
+you are doing.
+
+To better judge which ring needs adjustment, you can run
+the tube command with an extra parameter 't':
+
+tube piece.dat t
+
+This will cause the sections to be alternately colored
+bright green and red. Normally they would be painted in
+a nice wood-grain pattern. It is recommended to rn with
+this extra t until you are satisfied with the design, and
+then drop it to get normal colors. This only affects the
+diffusemap that is produced.
+
+The input format
+
+The input file starts with an integer to indicate the number
+of points along the circumference. Usually 16 is sufficient.
+(More points gives better quality, but makes Jocly slower.)
+Then follows a list of height-radius pairs describing the
+rings, as whitespace-separated real numbers. The total
+height of Jocly pieces is typically 3.0 - 3.5, while a
+radius 1.0 extends nearly to the edge of the square.
+ It is usually good practice to put each ring on a
+separate line, so you can easily see which numbers are
+heights, and which radii.
+
+Simple case: cylinder symmetry
+
+To create a cylindrically symmetric piece you only have
+to specify the height and radius of all the rings, which
+by default are each in a horizontal plane. The list must
+be followed by a specification of the output filenames,
+or it would be printed on the terminal. E.g.:
+
+16
+0.000 0.700
+0.050 0.700
+0.500 0.500
+0.860 0.860
+1.360 1.000
+1.860 0.860
+2.220 0.500
+2.360 0
+out: sphere
+
+This would describe a (rather course) sphere on a pedestal.
+The sphere in this case encompasses the top 5 sections;
+6 sections is about the minimum for a full sphere, but the
+lowest slice is replaced by the pedestal here.
+ Running Tube on this input will produce files sphere.js,
+sphere-diffusemap.bmp and spere-normalmap.bmp, which you
+then convert and copy to Jocly. Congratulations! You now
+created your first piece.
+
+Surface details
+
+After the specification of the output file you can still
+specify some details to be drawn on the maps: ridges and
+eyes. These don't affect the mesh file, but can create
+the illusion of extra structure.
+ A 'ridge' is drawn all around the object, parallel to
+the rings. There are two kind of ridges: V-shaped and U-
+shaped. To get one we have to write a line
+
+ridge: height width depth
+
+where the latter three are real numbers. The height is
+tricky as it does not correspond directly to the height
+at which you defined the rings, but is measured along
+the surface. This to be able to distinguish location
+on tube sections that are (nearly) horizontal, or even
+hanging down, (like the brim of a hat) so that the same
+height is passed multiple times.
+ To facilitate this, running tube will print a list of
+the rings, with the 'height along the surface' in the
+last column. You can use that as an aid to position the
+ridges.
+ The depth is positive for ridges lying on the surface,
+and negative for grooves. With positive width the ridge
+is V-shaped, with negative width it will be U-shaped.
+ There is a trick to optically soften acute angles
+between sections (which Jocly would not do automatically):
+You can put a V-shaped groove exactly at the connection
+to 'neuralize' the angle (like you shaved if off), and
+then an equally wide U-shaped ridge on top of that.
+
+Eyes are round, darkened pits. They are specified
+through a line
+
+eye: height angle size
+
+where 'height' is again the height measured along the
+surface. The 'angle' parameter specifies the horizontal
+location on the surface, as the angle with the forward
+direction (in degrees). So 60 would mean looking a bit
+forward but mostly sideways. Eyes are always created
+in symetrically-positioned pairs.
+ The eyes are drawn as circles on the maps, but because
+the maps can be highly distorted when transfered to the
+surface of the tube (depending on the local diameter
+and total height), they might show up elongated.
+
+It is possible to specify a different color for a tube
+section. To this end you must write behind the spec
+of the ring that finishes it
+
+paint: color
+
+or
+
+shade: color
+
+where 'color' is a hexadecimal color number (e.g. ff000
+for red). The difference is that 'paint' sets the color
+to the given one, while 'shade' will use the latter as
+an offset to add to the color it would normally generate.
+(Such that 101010 would make it a bit lighter, and
+f0f0f0 a bit darker.) This would preserve the wood-
+grain pattern in the section.
+ Note that it is possible to adjust the color of the
+entire object by specifying such a color offset on
+the command line as the 2nd argument.
+
+With these techniques you should already be able to
+produce pieces like they could be made out of turned
+wood with a laith. The lower part of pieces usually
+look very much alike, and once you have a satisfacory
+representation of that you can use it for creating
+multiple pieces by just putting different heads and
+hats on it.
+ Note that the .js file contains an over-all scaling
+factor, which by default is set to 1. By editing the
+file afterwards you could change that to shrink or
+expand the piece. So if your design turns out too
+tall after making all necessary adjustments to get the
+right shape, there is no need to change all the input
+numbers; you just change the scale. (Contrary to
+intuition larger scale makes the piece smaller.)
+
+Creating (modest) asymmetry
+
+For pieces that are mostly cylindrically symmetric, but
+have parts that stick out in one horizontal direction
+at some heights (such as the vizor of the Champion or
+the cap of the generals), we can shift some of the rings
+off axis by following the height-radius pair for that
+ring by a colon and two more real numbers. The first of
+these indicates the elliptic distortion of the ring: the
+width is multiplied by it. This causes indentation or
+protrusion in two diametrically opposit directions,
+either sideways of forward-backward. When the number is
+1 it has no effect, and the ring remains circular.
+Otherwise cylinder symmetry is broken, but the piece
+still has forward-backward mirror symmetry.
+
+The second number is the forward shift, in the same
+units as the radius. This causes a forward-backward
+asymmetry. To make the piece bulge out on one side
+you would specify a larger ring than the adjacent ones,
+but specify a shift equal to the increase in radius,
+so that one side stays in line with the other rings,
+and the opposit side bulges out twice as much.
+To prevent the larger radius makes the piece bulge
+out sideways too much, you can compensate the radius
+increase by specifying an ellipticity < 1.
+
+
+Bending
+
+So far all rings would be perfectly horizontal. It
+is possible to deviate from that by following the
+height-radius pair with a semicolon and two more
+real numbers. This can be done even after you specified
+an ellipticity & shift with the aid of a colon (but
+not before that!).
+ The first number indicates the (forward) tilt of the
+ring plane, as an angle in degrees. So 90 would make
+the ring stand up vertically, where what formerly was
+the front of the piece now points down. The center
+of the ring would stay on the vertical axis, so you
+would usually combine this with a forward shift to
+create a bended tube. To get a smooth bend you would
+of course need many intermediate angles, increasing
+the tilt in steps of maximally 15 degrees.
+ The second number is the 'up-curve' distortion.
+It bends the plane of the ring into a horizontal
+cylinder with a forward-pointing axis, like the ring
+is 'smiling'. This is done before applying any tilt.
+The number represents the radius of this cylinder.
+So to bend the ring into half a circle you would have
+to make that about 65% of the ring radius. This
+feature is not often needed; it was added for making
+the wings of the Phoenix, where a very narrow
+sideway ellipse is bent upwards.
+
+Giving an occasional ring a small tilt has an effect
+that is barely distinguishable from making it elliptic.
+So the tilt is mainly used to bend the tube that
+defines the piece in small steps to a large angle
+with the vertical, perhaps even inverting direction
+and grow downward again (such as in the Stork).
+ Because tilt and shift have to be combined to make
+the rings connect in a natural way, it is usually
+a pain to get this right. Especially on very tight
+curves of the tube. As an aid Tube not only prints
+the height-radius pairs, but also the coordinates
+of the forward-most point in each ring. This can
+tell you how much you have to adjust it horizontally
+and vertically to make the front of the piece curve
+in a smooth way.
+ This is not so helpful when you bend the tube
+backwards, so that the backward-most points get
+critically close together. But in that case you can
+first design the mirrored version that does bend
+forwards, and then flip the sign of all horizontal
+shifts and tilt angles.
+
+The 'lift' directive
+
+Sometimes you get something that looks like you want
+it, except that some section is too short. E.g. a
+piece with a complex hat, and you think the body should
+be just a bit taller. Of course you can increase the
+height coordinates in all rings above the top of the
+body by an equal amount to shift the head up, and
+repeat that until you get it right. But by putting a line
+
+lift: h,f
+
+with h and (optionally) f real numbers between the ring
+specifications you will shift all rings specified after
+it up by h, and forward by f. That makes positioning the
+upper part of a design much easier.
+ Lift directives are cumulative: the adjustment of
+height and forward shift of the specified rings always
+equals the sum of all preceding lift directives.
+
+Pseudo-rings
+
+Negative radii would make no sense, and the Tube program
+uses these as a kludge for changing some of its settings
+during the generation of the tube. In this case the
+parameter that normally indicates the height is interpreted
+for a different purpose. The actual (negative) value of the
+radius indicates which purpose.
+ Any negative radius terminates the tube we have generated
+so far, and makes the ring that follows start a new,
+disconnected tube. This way we can create multiple tubes.
+ When the radius = -1, the first parameter indicates the
+new number of points along the circumference to be used for
+all rings of the next tube.
+
+ When radius = -2, the tube that was just completed is
+duplicated. The first parameter in that case indicates how
+much the two instances will be shifted to the left and
+right. This is useful for making ears or horns.
+ When radius = -3, the latest tube is also duplicated.
+But in this case the instances are separated by applying
+a shear transformation, which shift each point by an amount
+that grows as we get further from the left-right plane: the
+forward-backward coordinate of a point is multiplied by the
+first parameter, and the result is added to or subtracted
+from the left-right coordinate. This can be used to 'unfold'
+wing structures.
+
+ When radius = -4, the first parameter represents an angle
+(in degrees). The whole structure that follows is then
+rotated by that angle around an axis that runs left-to-right,
+at the height of the last ring in the previous tube. This
+is the angular equivalent of the lift command, but unlike
+the latter can only occur once.
+
+
diff --git a/tube/copy.sh b/tube/copy.sh
new file mode 100755
index 00000000..7d98ac38
--- /dev/null
+++ b/tube/copy.sh
@@ -0,0 +1,5 @@
+convert test-diffusemap.bmp test-diffusemap.jpg
+convert test-normalmap.bmp test-normalmap.jpg
+cp test-diffusemap.jpg ~/jocly/dist/browser/games/chessbase/res/staunton/rook/rook-diffusemap.jpg
+cp test-normalmap.jpg ~/jocly/dist/browser/games/chessbase/res/staunton/rook/rook-normalmap.jpg
+cp test.js ~/jocly/dist/browser/games/chessbase/res/staunton/rook/rook.js
diff --git a/tube/gold.dat b/tube/gold.dat
new file mode 100644
index 00000000..cc6c70e3
--- /dev/null
+++ b/tube/gold.dat
@@ -0,0 +1,32 @@
+16
+0.000 0.720
+0.075 0.755
+0.211 0.620
+0.337 0.710
+0.705 0.521
+0.992 0.342
+1.571 0.241
+lift: 0.001
+1.620 0.413
+1.750 0.264
+1.830 0.348
+1.955 0.420
+2.115 0.450
+2.273 0.420
+2.400 0.348
+2.433 0.310
+2.440 0.480: 0.75 0.165 paint: 101010
+2.520 0.320; -15 0
+2.710 0.360
+2.711 0
+out: test
+ridge: 2.168 -0.07 0.10
+ridge: 2.058 -0.06 0.05
+ridge: 1.978 -0.07 0.05
+ridge: 0.690 0.12 -0.10
+ridge: 0.830 0.12 -0.05
+ridge: 0.4292 0.15 -0.07
+ridge: 0.4292-0.15 0.07
+ridge: 0.0828 0.15 -0.09
+ridge: 0.0828 -0.15 0.09
+
diff --git a/tube/stork.dat b/tube/stork.dat
new file mode 100644
index 00000000..dc8bee88
--- /dev/null
+++ b/tube/stork.dat
@@ -0,0 +1,35 @@
+16
+0.000 0.720
+0.075 0.755
+0.211 0.620
+0.337 0.710
+0.705 0.521 shade: 101010
+0.705 0.340
+1.000 0.340: 1.00 -0.050
+1.300 0.340: 1.00 -0.200
+1.600 0.340: 1.00 -0.400
+1.900 0.360: 1.00 -0.550
+2.200 0.380: 1.00 -0.600
+2.300 0.407: 1.00 -0.595; 15 0
+2.397 0.413: 1.00 -0.560; 30 0
+2.495 0.420: 1.00 -0.495; 45 0
+2.570 0.430: 1.00 -0.415; 60 0
+2.625 0.440: 1.00 -0.314; 75 0
+2.650 0.450: 1.00 -0.200; 90 0
+2.630 0.450: 1.00 -0.100; 105 0
+2.570 0.470: 1.00 -0.000; 120 0
+2.510 0.440: 1.00 0.120; 135 0
+2.360 0.415: 1.00 0.170; 150 0
+2.180 0.350: 1.00 0.270; 150 0
+2.000 0.230: 1.00 0.350; 150 0 shade: e0e0e0
+0.900 0.010: 1.00 0.820; 180 0
+out: test
+ridge: 0.690 0.12 -0.10
+ridge: 0.830 0.12 -0.05
+ridge: 0.4292 0.15 -0.07
+ridge: 0.4292-0.15 0.07
+ridge: 0.0828 0.15 -0.09
+ridge: 0.0828 -0.15 0.09
+eye: 3.85 100 0.15
+
+
diff --git a/tube/tube.c b/tube/tube.c
new file mode 100644
index 00000000..be093bff
--- /dev/null
+++ b/tube/tube.c
@@ -0,0 +1,329 @@
+#include
+#include
+
+#define NMAX 10000
+#define NRING 100
+#define PI (4*atan(1.))
+
+int test, nr, poly, nvert, nuvs, nface, nridge, neye, fcolor = 0xff0000, colorAdjust, startRing, startVert;
+double maxh = 0, nod, nodStart, shake;
+double height[NRING], radius[NRING], dist[NRING], squeeze[NRING], shift[NRING], slant[NRING], curve[NRING], ridges[NRING], eyes[NRING];
+double normH[NRING], normR[NRING];
+int paint[NRING];
+int noiseV[512], grain[512];
+double vertices[3*NMAX], uvs[2*NMAX];
+int faces[9*NMAX];
+
+// map stuff
+char q[54] = {0102,0115,066,0,014,0,0,0,0,0,066,0,0,0,050,0, 0,0,0,2,0,0,0,2,0,0,1,0,030,0,0,0, 0,0,0,0,014 }; // MS bmp header for 512x512 24-bit
+int diffuse[512*512], normal[512*512]; // color data
+
+long long int seed;
+int MyRandom()
+{
+ seed = 90752627 * (seed | 1);
+ return (int) (seed >> 16 & 0x7fffffff);
+}
+
+double Gaussian()
+{
+ double res = 0; int i;
+ for(i=0; i<12; i++) res += (MyRandom() & 0x1fffff) - 0xfffff;
+ return res/(2.*1024*1024);
+}
+
+double Noise(int n, double spec[])
+{
+ double res = 0; int i;
+ for(i=0; i<10; i++) res += spec[2*i]*cos(PI*(i+1)*n/208.) + spec[2*i+1]*sin(PI*(i+1)*n/208.);
+}
+
+void MakeWood()
+{
+ double x, specH[20], specV[20];
+ int i, n;
+ for(i=0; i<20; i++) {
+ specH[i] = Gaussian();
+ specV[i] = Gaussian()/(1. + (i>>1)*(i>>1));
+ }
+ for(i=0; i<416; i++) noiseV[i] = 5*Noise(i, specV);
+ for(i=0; i<416; i++) {
+ double shift = Noise(i, specH);
+ double x = 0.5+0.5*cos(((int)(100*(i+shift+20))%2000)*PI/2000.);
+ n = 18*x*x;
+ grain[i] = n*0x010100; // yellow
+ }
+}
+
+double Angle(double x1, double y1, double x2, double y2)
+{ // actually the cosine of the angle between the vectos
+ double l1 = x1*x1+y1*y1;
+ double l2 = x2*x2+y2*y2;
+ return (x1*x2 + y1*y2)/sqrt(l1*l2);
+}
+
+double Tilt(int n, int which)
+{
+ double w1 = (n ? dist[n] - dist[n-1] : radius[0]);
+ double w2 = dist[n+1] - dist[n];
+ double wt = w1 + w2;
+ double a, avgH, avgR;
+ if(w2/wt < 0.1) w2 = 0; // narrow ridge adapts fully to adhjacent
+ if(w1/wt < 0.1) w1 = 0;
+ a = Angle(normH[n], normR[n], normH[n+1], normR[n+1]);
+ if(a < 0.6) return 0; // no smoothening if angle isn't blunt enough
+ avgH = (normH[n]*w1 + normH[n+1]*w2)/wt; // weighted average of normals
+ avgR = (normR[n]*w1 + normR[n+1]*w2)/wt; // ... to which we adapt
+ if(which) {
+ a = Angle(avgH, avgR, -normR[n+1], normH[n+1]);
+ } else {
+ a = Angle(avgH, avgR, -normR[n], normH[n]);
+ }
+ return 127*a;
+}
+
+void Ring(int k, int n)
+{
+ double h = height[k], r = radius[k], d = dist[k], e = squeeze[k], s = shift[k], t = slant[k], Y, Z;
+ int i, j, color, first = nvert, fuv = nuvs;
+ t *= PI/180.;
+ for(i=0; i>2, gradG = 3*(color&0xff00)<<6, gradB = 3*(color&0xff)<<14;
+ if(normH[k] < (!t1 && !t0 ? -0.80 : -0.90)) color = 0x322822, gradR = gradB = gradG = 0;
+ }
+ color += colorAdjust;
+ if(paint[k] & 1<<24) color = paint[k] & 0xffffff; else color += paint[k];
+ gradR /= top - bottom; gradG /= top - bottom; gradB /= top - bottom;
+ for(j=bottom; j<=top; j++) {
+ double r = (radius[k-1]*(top - j) + radius[k]*(j - bottom))/(top - bottom);
+ double s = (shift[k-1]*(top - j) + shift[k]*(j - bottom))/(top - bottom);
+ double e = (squeeze[k-1]*(top - j) + squeeze[k]*(j - bottom))/(top - bottom);
+ for(i=0; i<=width; i++) {
+ int z = ((cos(PI*i/208.) + e*sin(PI*i/208.))*r-s)*0.5*208. + 208;
+ int c = color - grain[(z+noiseV[j])%416] - ((top-j)*gradR & 0xff0000) - (((top-j)*gradG & 0xff0000)>>8) - (((top-j)*gradB & 0xff0000)>>16);
+ if(test) c = ((i-208)%52 ? fcolor : 0xffff00);
+ diffuse[512*j+i] = c;
+ }
+ for(i=421; i<425; i++) diffuse[512*j+i] = fcolor; // section markers
+ }
+ fcolor ^= 0xffff00;
+ // normalmap
+ printf("ring %d: (h,r)=(%6.4f,%6.4f) front: (%6.4f,%6.4f) along surface: %6.4f\n",k,h,r,h-r*sin(t),s+r*cos(t),dist[k]);
+t0=t1=0;
+ for(j=bottom; j<=top; j++) {
+ int col = 0x808080; // grey
+ double x = 2.*(j-bottom)/(top-bottom) - 1;
+ int green = (x*x*0.75 - 0.25)*(t1+t0) + 0.5*x*(t1-t0); // 2nd orde interpolation keeping average 0
+ if(green > 127) green = 127;
+ col += green << 8 & 0xff00;
+ col += sqrt(127*127-green*green) + 0.5;
+ for(i=0; i<=width; i++){
+ normal[512*j+i] = col;
+ }
+ }
+ }
+}
+
+void Cone(int k, int n)
+{
+ double h = height[k], d = dist[k], e = squeeze[k], s = shift[k];
+ int i, j, first = nvert, fuv = nuvs;
+ vertices[3*nvert] = 0;
+ vertices[3*nvert+1] = h;
+ vertices[3*nvert+2] = s;
+ nvert++;
+ for(i=0; i 127) d = 127;
+ if(d < -127) d = -127;
+ for(j=0; j<=hw; j++) {
+ int x = d*f + (1-f)*d*j/hw << 8;
+ for(i=0; i<=420; i++) normal[512*(h-j)+i] += x, normal[512*(h+j)+i] -= x;
+ }
+}
+
+void DrawEyes(int n)
+{
+ int w = 416*eyes[n+1]/360 + 0.5;
+ int h = 416*eyes[n]/maxh + 0.5;
+ int d = 208*eyes[n+2]/maxh + 0.5;
+ int hw, i, j, f = 1;
+ for(j= -d; j<=d; j++) {
+ for(i=-d; i<=d; i++) if(i*i + j*j <= d*d) {
+ int r = 127*i/d, g = 127*j/d;
+ normal[512*(h+j)+208+w+i] += r<<16 | g<<8;
+ normal[512*(h+j)+208-w+i] += r<<16 | g<<8;
+ diffuse[512*(h+j)+208+w+i] -= 0x404040;
+ diffuse[512*(h+j)+208-w+i] -= 0x404040;
+ }
+ }
+}
+
+int main(int argc, char **argv)
+{
+ char name[200] = "tube.dat", out[200]="", *p = name;
+ FILE *f;
+ double h, r, u, s, t, c, lift = 0, forward = 0;
+ int i, j;
+ if(argc > 1) p = argv[1];
+ if(argc > 2) if(sscanf(argv[2], "%x", &colorAdjust) != 1) test++;
+ f = fopen(p, "r");
+ if(!f) { printf("no input file: %s\n", name); return 1; }
+ fscanf(f, "%d lift: %lf", &poly, &lift);
+ while((fscanf(f, "%lf %lf", &h, &r)) == 2) {
+ if(r >= 0) h += lift;
+ height[nr] = h; radius[nr] = r;
+ if(r < 0) { startRing = ++nr; continue; }
+ seed ^= (int) (1000*h);
+ u = 1; s = t = c = 0; // default: no squeeze, shift or tilt
+ fscanf(f, ": %lf %lf", &u, &s);
+ fscanf(f, "; %lf %lf", &t, &c);
+ squeeze[nr] = u; shift[nr] = s += forward; slant[nr] = t; curve[nr] = c;
+ if(nr != startRing) {
+ double x = h - height[nr-1], y = r - radius[nr-1], z = s - shift[nr-1], len;
+ if(r) maxh += len = sqrt(x*x + y*y + z*z);
+ // calculate normal
+ normH[nr] = -y/len; normR[nr] = x/len;
+ } else normH[0] = -1; // bottom faces down
+ dist[nr++] = maxh;
+ if(fscanf(f, " paint: %x", &j) == 1) paint[nr] = j | 1<<24;
+ if(fscanf(f, " shade: %x", &j) == 1) paint[nr] = j & 0xffffff;
+ if(fscanf(f, " lift: %lf", &h) == 1) lift += h, h = 0, fscanf(f, ", %lf", &h), forward += h;
+ if(r <= 0 || u == 0) startRing = nr;
+ }
+
+ MakeWood();
+
+ fscanf(f, " out: %s", out);
+ while(fscanf(f, " ridge: %lf %lf %lf", ridges+nridge, ridges+nridge+1, ridges+nridge+2) == 3) nridge += 3, printf("ridge\n");
+ while(fscanf(f, " eye: %lf %lf %lf", eyes+neye, eyes+neye+1, eyes+neye+2) == 3) neye += 3, printf("eye\n");
+
+ startRing = 0;
+ for(i=0; i>8, diffuse[i]>>16);
+ fclose(f);
+
+ sprintf(name, "%s-normalmap.bmp", out);
+ f = fopen(name, "w");
+ for(i=0; i<54; i++) fprintf(f, "%c", q[i]);
+ for(i=0; i<512*512; i++) fprintf(f, "%c%c%c", normal[i], normal[i]>>8, normal[i]>>16);
+ fclose(f);
+
+ return 0;
+}
+
diff --git a/tube/wizard.dat b/tube/wizard.dat
new file mode 100644
index 00000000..dd95b7a6
--- /dev/null
+++ b/tube/wizard.dat
@@ -0,0 +1,33 @@
+16
+0.000 0.720
+0.075 0.755
+0.211 0.620
+0.337 0.710
+0.705 0.521
+0.992 0.342
+1.571 0.241
+1.620 0.413
+1.750 0.244
+1.830 0.280
+1.955 0.335
+2.115 0.350
+2.273 0.335
+2.320 0.312
+2.150 0.580
+2.323 0.317
+3.000 0.100
+3.052 0.050
+3.065 0
+out: test
+ridge: 2.168 -0.07 0.10
+ridge: 2.058 -0.06 0.05
+ridge: 1.978 -0.07 0.05
+ridge: 0.690 0.12 -0.10
+ridge: 0.830 0.12 -0.05
+ridge: 0.4292 0.15 -0.07
+ridge: 0.4292-0.15 0.07
+ridge: 0.0828 0.15 -0.09
+ridge: 0.0828 -0.15 0.09
+
+
+