Hello,
I have been trying for some time now to generate a procedural terrain with multiple biomes based on height, temperature and moisture. I am new in all of this, so this is my first game I am building. I know this is a complex thing to do, and I should have started with something less complicated, but I also like to deep dive in anything, not keeping back on anything just because it’s complex
So yeah, this is my first post here aswell.
Now, to the point. Each biome has an index; e.g. 1 or 2 or 3 or 4 or 5 based on the combination of the height, temperature and moisture.
I am keeping these information in each vertex in the uv2 channel, in a Vector2 (biomeIndex, 0).
This is an example of the map I have with biomes distribution. This is just a test and by far not a realistic one, but still works for now, so don’t judge me too harsh for the distribution
The problem I have is that when each biome texture is being drawn by Shader Graph, it is also drawing the biomes textures that are before the one the current biome is being drawn. Check picture bellow to see what I mean:
As you can see, here are the extra textures that I want to be removed, the ones with x. The circles are vertexes examples in which the uvs2 info is kept. All mesh vertices have these informations, not only the ones circled.
And this is the Shader Graph I am using:
What am I doing wrong? I have tried the comparison for Equal, or Grater than, etc, all ending up in a worse situation in which textures were overlapping. Also, note that even in this case, some texture are overlapping, creating this effect:
Could someone please point me into the right direction? Also, an advice regarding the blending of the biomes between eachother? Would be awesome! I know I can use Lerp and Inverse Lerp for these but from what I’ve tried so far just makes the blending way too large, not just a little where biomes meet.
Thank you for reading the long post!




