-
Notifications
You must be signed in to change notification settings - Fork 0
Controllers
Ben edited this page Jul 20, 2019
·
2 revisions
MonoBehaviour
This script is the entry point of using the asset in Unity.
-
Generate On Startup
: should the map be generated when this script is started ? (this will callGenerate()
followed byDraw()
in theStart
method) -
Settings
: the Hexamap settings object to use when generating maps with this controller -
Parent
: the GameObject to use as a parent of the generated tiles. If none is specified, the controller will create a GameObject called "Hexamap" at the root of the scene -
public void Generate()
: generate the data of the map -
public void Draw()
: select prefabs and position them in the scene based on the generated map -
public void Destroy()
: destroy GameObjects and data associated to the map
MonoBehaviour
This controller will be attached to every tiles generated by the HexamapController
. This is the bridge between the GameObject of the tile and the library's model. You can grab the model by accessing the Tile Model
property of this script.