Hi!
Can you, or actually, how can you access the names of the textures in a terrain?
Like:
texture 1 = snow.jpg
texture 1 = dirt.jpg
etc.
I already have access to the TerrainData variable but I can’t figure out this one
Thanks!
Hi!
Can you, or actually, how can you access the names of the textures in a terrain?
Like:
texture 1 = snow.jpg
texture 1 = dirt.jpg
etc.
I already have access to the TerrainData variable but I can’t figure out this one
Thanks!
Solved.
var terrainTexture:SplatPrototype = terrainData.splatPrototypes[n];
Debug.Log("name=" + terrainTexture.texture.name);
did it!
Hi, I know this post is old, but could you elaborate how you did this? I’ve looked at your code but I have no idea how to get the terrainData from the current active terrain. (sorry, I’m sort of new to programming)
Never mind, you get it with Terrain.activeTerrain.terrainData;