I'm experimenting with procedural landscape generation and paging terraintiles. Every TerrainTile has a Unity Terrain and is being populated with heights. I am having some difficulties with building the TerrainData object for each terrain.
In this case my goal is a terrain tile of 1km square in size with a resolution of 129. My initial assumption was I could set the desired size and feed the TerrainData object with a 129x129 array of floats.
Naturally. It isn't that easy. For this purpose the SetHeights method is needed but it has no description so I haven't a clue how to use it.
Through some experimentation and studying the exceptions the mapsize seems set to 33, with no way to change it. And I have no idea what the xBase and yBase mean.
Am I looking at this from the wrong angle? It would be great if someone could explain this in more detail.