HexPlanet is a scripting framework to procedurally generate tiled spheres composed of hexagons and pentagons allowing you to generate planets with individual tiles and a world of possibilities. The package consists of several scripts which perform the difficult task of building a perfectly tiled sphere with all of the infrastructure set up to allow you to build a tile based game that stands out from the crowd.
The Pro version includes advanced features, tools and templates that will make it easier and faster than ever to get your game up and running.
Update:
Version 1.6 introduces an all new terrain editor for scene view editing of generated planets!
Select a terrain tool from the custom inspector and paint onto the planet with a variable brush size to quickly and intuitively edit your planet! Paint tile extrusion heights, material, navigation path cost and even place prefabs with the brush.
Weve also added a quick way to save planets as prefabs so you can easily store your edited planets and load them into your scenes both in editor or at runtime!
Version 1.5 includes a bunch of optimizations to the planet generation code making the planet construction much faster. The code is also much simpler making it easier to read and understand.
Lots of new features have been added:
-Option to invert the planet so that all tiles face inwards towards the planet's center a la Dyson Sphere
-Option to generate the planet as a single mesh without the generation of any Tile gameobjects
-Option to generate tile colliders along with a dropdown to select the collider type (Box, Sphere or Mesh)
-Inspector buttons on tiles to select a group of tiles according to several parameters, such as group ID, extrusion height, navigation path cost and connected regions. This makes precise editing of your planet super quick and easy!
-New example scene showing unit movement on the planet. Just click on a tile to have the demo unit navigate to that tile along the shortest path.
Tile Extrusion
-Custom Inspector button for Tiles allows you to specify a height and execute extrusions which raise/lower the selected Tile(s) along their local up
-Generates new mesh geometry for a solid hexagonal/pentagonal prism shaped Tile
Custom Editor Interfaces
-Custom Inspector buttons and sliders let you generate and adjust the HexPlanet in the Unity Editor
-Scale slider to change the size of the planet in Edit mode and update the tiles accordingly
-Custom Tile inspector buttons allow you to easily spawn or place any object onto the selected tile and automatically aligns the object to that tile!
-Select multiple Tiles and mass place objects with a single click!
Fast Spherical Pathfinding:
-Find the shortest path between any two tiles, if it exists, and return a stack of tiles indicating the path.
-Options to set certain tiles as "non-navigable" and ability to specify a navigation matrix so that some units cannot move on certain tiles while others can.
-Assignable tile weights so that the path finder prioritizes tiles of a certain type that you can customize to mimic terrain changes on your planet
Enclosed Region Detection:
-Functions allowing you to select any tile and find all connected tiles of a certain type.
-Useful for identifying "islands" of tiles surrounded by non-navigable tiles or enemy tiles etc.
Unit Movement Templates:
-Scripts which can act as the base class for any units that need to move around the sphere.
-Handles properly aligning the unit's transform forward to their movement heading and correctly rotates them around the sphere when passed a path from the pathfinder
Support for Multiple Planets:
-Ability to have multiple independent hex planets simultaneously exist in the same scene