Terrain collision detection


Does any one have a simple code for collision detection with terrain? So when i use my model on terrain with mountains, etc. it will not pass by the mountain but go up or down etc.

Maybe the tutorials will get you started.


Do you know is it possiblee to use more than 3 (RGB) textures for heightmap?


Its in this tutorial: https://wiki.jmonkeyengine.org/legacy/doku.php/jme3:beginner:hello_terrain

“Splat textures are based on the Terrain.j3md material defintion. If you open the Terrain.j3md file, and look in the Material Parameters section, you see that you have several texture layers to paint on: Tex1, Tex2, Tex3, etc.”