bothack.position
->Position
(->Position x y)
Positional factory function for class bothack.position.Position.
adjacent?
(adjacent? pos1 pos2)
at
(at level x y)
(at level {:keys [x y], :as pos})
Tile of the level at given terminal position
diagonal-neighbors
(diagonal-neighbors tile)
(diagonal-neighbors level tile)
diagonal?
(diagonal? from to)
distance
(distance from to)
distance-manhattan
(distance-manhattan from to)
in-direction
(in-direction level from dir)
(in-direction from dir)
including-origin
(including-origin nbr-fn pos)
(including-origin nbr-fn level pos)
Include origin position in given *neighbors function results
map->Position
(map->Position m__5869__auto__)
Factory function for class bothack.position.Position, taking a map of keywords to field values.
neighbors
(neighbors level tile)
(neighbors pos)
position
(position x y)
(position of)
position-map
(position-map of)
When an actual map is desired (position records are not completely equal to
{:x X :y Y})
rectangle
(rectangle NW-corner SE-corner)
rectangle-boundary
(rectangle-boundary NW-corner SE-corner)
straight-neighbors
(straight-neighbors tile)
(straight-neighbors level tile)
straight?
(straight? from to)
to-position
(to-position pos)
Sequence of keys to move the cursor from the corner to the given position
valid-position?
(valid-position? x y)
(valid-position? {:keys [x y]})