Hex-grid geometry — pointy-top, ODD-R OFFSET coordinates: coordinate/pixel conversion, neighbours, distance, corners and canonical edges, plus a square local basis for right-angled structures placed on the hex world.
loft install hex_grid
use hex_grid;
| Guide | getting started with hex_grid |
|---|---|
| Version | 0.1.4 — published 2026-10-05 |
| Categories | Geometry |
| Requires | loft >=0.8.5 |
| Compatibility | API: drop-in for 0.1.0 and later · stored data: drop-in for 0.1.0 and later |
| Download | 20 kB |
| Public API | 19 items, with their documentation |
| Dependencies | none |
| Used by | hex_draw · hex_fit · hex_form · hex_shape · hex_terrain |
| Source | read it here — the libraries are written in loft |
| Repository | https://github.com/loft-lang/loft-libs-world/tree/main/hex_grid |
A drop-in floor is the oldest release of this package the current one still replaces without a source change. Not declared means exactly that — the package has made no promise, which is the honest state for one published before the compatibility contract existed.