Fix creating new tabula board
This commit is contained in:
parent
e584ab416d
commit
d112a9463c
1 changed files with 1 additions and 1 deletions
2
board.go
2
board.go
|
@ -44,7 +44,7 @@ type Board [boardSpaces]int8
|
|||
// NewBoard returns a new board with checkers placed in their starting positions.
|
||||
func NewBoard(variant int8) Board {
|
||||
if variant != VariantBackgammon {
|
||||
return Board{15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -15, 0, 0, 0, 0, 0, 0, 0, 0, 1}
|
||||
return Board{15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -15, 0, 0, 0, 0, 0, 0, 0, 0, variant}
|
||||
}
|
||||
return Board{0, -2, 0, 0, 0, 0, 5, 0, 3, 0, 0, 0, -5, 5, 0, 0, 0, -3, 0, -5, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue