Liking cljdoc? Tell your friends :D

hive.core.domain.board


board-movement-metaclj

(board-movement-meta board)

examine all occupied positions of a board, and compile simple movement meta information

examine all occupied positions of a board, and compile simple movement meta information
sourceraw docstring

can-slide-lookup-tableclj

source

can-slide-lookup-table-seedclj

source

count-piecesclj

(count-pieces board)
(count-pieces board color-filter type-filter)

count number of pieces on the board, with optional filtering by color and/or type

count number of pieces on the board, with optional filtering by color and/or type
sourceraw docstring

createclj

initialize an empty board with no pieces

initialize an empty board with no pieces
sourceraw docstring

encode-slide-lookup-key-from-adjacenciesclj

(encode-slide-lookup-key-from-adjacencies position-adjacencies)

transform a list of adjacency descriptors into a can-slide table lookup key

transform a list of adjacency descriptors into a can-slide table lookup key
sourceraw docstring

generate-can-slide-lookup-tableclj

(generate-can-slide-lookup-table seed)
source

lookup-adjacent-climb-positionsclj

(lookup-adjacent-climb-positions board position)

return a list of positions onto which a piece at the given position could climb

return a list of positions onto which a piece at the given position could climb
sourceraw docstring

lookup-adjacent-positionsclj

(lookup-adjacent-positions board position)

lookup neighboring positions as a directional map

lookup neighboring positions as a directional map
sourceraw docstring

lookup-adjacent-slide-positionsclj

(lookup-adjacent-slide-positions board position)

return a list of positions into which a piece at the given position could slide

return a list of positions into which a piece at the given position could slide
sourceraw docstring

lookup-occupied-adjacenciesclj

(lookup-occupied-adjacencies board position)

return list of occupied adjacencies

return list of occupied adjacencies
sourceraw docstring

lookup-occupied-positionsclj

(lookup-occupied-positions board)

returns the occupied positions of board as a set

returns the occupied positions of board as a set
sourceraw docstring

lookup-piececlj

(lookup-piece board position)

get the visible (top) piece at the stack specified by position

get the visible (top) piece at the stack specified by position
sourceraw docstring

lookup-piece-at-heightclj

(lookup-piece-at-height board position idx)

get the piece at position residing at height in the stack, or nil

get the piece at position residing at height in the stack, or nil
sourceraw docstring

lookup-piece-stackclj

(lookup-piece-stack board position)

return the stack of pieces at position

return the stack of pieces at position
sourceraw docstring

lookup-piece-stack-heightclj

(lookup-piece-stack-height board position)

get the number of pieces at position

get the number of pieces at position
sourceraw docstring

lookup-slide-destinationsclj

(lookup-slide-destinations board start-position)

return a list of possible destinations that can be reached from a given starting position by only sliding

return a list of possible destinations that can be reached from a given starting position by only sliding
sourceraw docstring

move-piececlj

(move-piece board position-0 position-1)

remove piece from board at position-0 and place it at position-1

remove piece from board at position-0 and place it at position-1
sourceraw docstring

originclj

origin of the board addressing system — see doc/grid.png

origin of the board addressing system — see doc/grid.png
sourceraw docstring

place-piececlj

(place-piece board piece position)

place a piece on the top of a stack at position

place a piece on the top of a stack at position
sourceraw docstring

purge-emptiesclj

(purge-empties pieces)

remove empty piece-stacks from board

remove empty piece-stacks from board
sourceraw docstring

remove-piececlj

(remove-piece board position)

remove the piece at the top of the stack at position

remove the piece at the top of the stack at position
sourceraw docstring

render-valid-positions-from-slide-lookup-valclj

(render-valid-positions-from-slide-lookup-val slide-lookup-val origin-position)

transform a can-slide table lookup value into a filtered list of positions

transform a can-slide table lookup value into a filtered list of positions
sourceraw docstring

search-piecesclj

(search-pieces {pieces :pieces} color-filter type-filter)

search all pieces on the board, filtering by color and/or type

search all pieces on the board, filtering by color and/or type
sourceraw docstring

search-top-piecesclj

(search-top-pieces board color-filter type-filter)

search only the top pieces of each stack on the board, filtering by color and/or type

search only the top pieces of each stack on the board, filtering by color and/or type
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close