Log in

View Full Version : Hex <-> Coordinates conversion for scripts


Suicide Junkie
December 21st, 2007, 06:15 PM
If you want to convert hex IDs into system map coordinates, you'll need these functions http://forum.shrapnelgames.com/images/smilies/happy.gif

Useful for:
- Moving ships a certain number of hexes (In GGmod, ships ending turn on a warppoint are shoved 1 hex in a random direction so that chokepoints aren't.
- Swirling ships around as they go down into the black hole.
- If you wanted to, you could make planets orbit their stars, although it would tend to cause trouble with ship navigation http://forum.shrapnelgames.com/images/smilies/happy.gif
- Stargates. Players can dial an address using map coords, and you can now figure out what hex ID you need to use for the warppoint's destination.