flins.support.hexmath package¶
Submodules¶
flins.support.hexmath.axial module¶
Grid-scale computing. Axial coordinates.
Hexagonal axial coordinate helper functions, assuming pointy side up.
flins.support.hexmath.cube module¶
Cubic coordinate helper functions assuming pointy side up.
- This draws heavily from the excellent reference:
-
flins.support.hexmath.cube.
closest
(i, j, k, points)[source]¶ Which point (in a list) is closest to a single passed point?
-
flins.support.hexmath.cube.
distance
(i_1, j_1, k_1, i_2, j_2, k_2)[source]¶ Distance between two hexagons in cube coordinates
-
flins.support.hexmath.cube.
neighbors
(i, j, k)[source]¶ Give me a list of neighboring hexagon locations
-
flins.support.hexmath.cube.
rotate_about_center
(i, j, k, n_steps)[source]¶ Rotate the coordinate i,j,k about the 0,0,0 center by n_steps
Each step is one 60 degree rotation to the right. Negative steps are 60 degree rotations to the left.
flins.support.hexmath.offset module¶
Grid-scale computing. Offset coordinates.
Hexagonal offset coordinate helper functions, assuming pointy side up.