private void createCollisionMarkers(int num) {
        for (int i = 0; i < num; i++) {
            Sphere s = new Sphere(6, 6, 1);
            Geometry collisionMarker = new Geometry("collisionMarker");
            collisionMarker.setMesh(s);
            Material mat = new Material(assetManager, "Common/MatDefs/Misc/Unshaded.j3md");
            mat.setColor("Color", i == 0 ? ColorRGBA.Orange : ColorRGBA.Blue);
            collisionMarker.setMaterial(mat);
            rootNode.attachChild(collisionMarker);
            collisionMarkers.add(collisionMarker);
        }
    }
Creates a terrain object and a collision node to go with it. Then
drops several balls from the sky that collide with the terrain
and roll around.
Left click to place a sphere on the ground where the crosshairs intersect the terrain.
Hit keys 1 or 2 to raise/lower the terrain at that spot.

@author Brent Owens
jme3-examples/src/main/java/jme3test/terrain/TerrainTestCollision.java