(define "Columns" ) (define "PiecesOwnedBy" (count in:(sites #1 "Home"))) //------------------------------------------------------------------------------ (game "Tshuba" (players 2) (equipment { (mancalaBoard 4 "Columns" store:None { (track "Track1" "0,E,N1,W" loop:True P1) (track "Track2" loop:True P2) } ) (regions "Home" P1 (sites Track "Track1")) // P1 Home (regions "Home" P2 (sites Track "Track2")) // P2 home (regions "Inner" P1 (difference (sites Track "Track1") (sites Bottom))) // P1 inner Home (regions "Inner" P2 (difference (sites Track "Track2") (sites Top))) // P2 inner Home (piece "Seed" Shared) (hand Each) }) (rules (start (set Count 2 to:(union (sites P1 "Home") (sites P2 "Home")))) (play (if (= 1 (var "ExtraCapture")) (move Remove (difference (sites Next "Home") (sites Empty)) count:(count at:(to)) (then (set Var "ExtraCapture" 0)) ) (move Select (from (if ("SameTurn") "LastHoleSowed" (sites Mover) ) if:(< 0 (count at:(from))) ) (then (sow "Track" owner:(mover) apply:(if (< 1 (count at:(to))) (moveAgain) (if (is In (to) (sites Mover "Inner")) (and { (if (> (count at:("OppositePit" (to))) 0) (remove ("OppositePit" (to)) count:(count at:("OppositePit" (to)))) ) (if (> (count at:("OppositeOuterPit" (to))) 0) (remove ("OppositeOuterPit" (to)) count:(count at:("OppositeOuterPit" (to)))) ) (set Var "ExtraCapture" 1) (moveAgain) }) ) ) ) ) ) ) ) (end (if (all Sites (sites Next "Home") if:(= 0 (count at:(site)))) (result Mover Win) ) ) ) ) //------------------------------------------------------------------------------ (option "Board Size" args:{ } { (item "4" <4> <"8,E,N1,W"> "Each player has 4 holes on each row.")* (item "8" <8> <"16,E,N1,W"> "Each player has 8 holes on each row.") (item "10" <10> <"20,E,N1,W"> "Each player has 10 holes on each row.") (item "16" <16> <"32,E,N1,W"> "Each player has 16 holes on each row.") (item "22" <22> <"44,E,N1,W"> "Each player has 22 holes on each row.") }) //------------------------------------------------------------------------------ (rulesets { (ruleset "Ruleset/Tshuba (Described)" { "Board Size/4" } variations:{"Board Size/8" "Board Size/10" "Board Size/16" "Board Size/22"} )* }) //------------------------------------------------------------------------------ (metadata (info { (description "Tshuba is a four-row mancala-style board game played by the Tsonga people of southeast Africa. It may be played on boards with four to 22 holes per row, and is similar to other games in the region.") (aliases {"Shimuana"}) (rules "4x4, 8, 10, 16, or 22 board. Two counters in each hole. Sowing occurs in an anti-clockwise direction. When the final counter of a sowing lands in an occupied hole, the contents are picked up and sowing continues. When the final counter lands in an empty hole in the player's inner row, the contents of the opponent's hole in the inner row opposite it are captured, and if there are counters also in the corresponding outer row hole, these are also captured. The player may also capture from another hole from the opponent's side of the board of their choosing. The turn ends. If the final counter lands in an empty hole in the player's outer row, the turn ends. Play continues until one player captures all of the opponent's counters, thus winning.") (source "Junod 1912: 314-318.") (id "258") (version "1.3.12") (classification "board/sow/four rows") (credit "Eric Piette") (origin "This game was played in Mozambique, around 1912.") } ) (graphics { (board Style Mancala) }) (ai "Tshuba_ai" ) )