Terrain layer paint visual fail...

Check out “Height blending” here:

https://docs.unrealengine.com/latest/INT/Engine/Landscape/Materials/#layerblending

This is just one method of doing it. If you use “layer samples” instead of the blend nodes, you can use “linear interpolate” nodes to blend the individual part of your materials however you want. I’d start with simple height blending though.