Hi, all!
In my new game I have a terrain that is made up of different tiles, because some of them are to be replaced with prefabs (assets) of the required size. I want to check at all times that my First Person Controller remains above the terrain, using the well-known
transform.position.y = Terrain.activeTerrain.SampleHeight(transform.position) + Terrain.activeTerrain.transform.position.y;
Problem: when I leave the original tile for an adjacent one, SampleHeight no longer works correctly ; it looks as if the heightmap information has been lost or is not updated properly.
Any ideas ?
Thanks in advance,
Thierry