BadAss' Autopilot
This little example mission shows some kind of autopilot. The autopilot lets your chopper fly constantly in a height of 25 m above the ground, automatically. With the autopilot you can easily fly over steep cliffs. Flying over high houses can lead to crashs anyway.
The correction of your flying height is done with the SetVelocity command. The script is scanning the terrain below the chopper as well as in front of it constantly. The actual height is compared with the programmed height and corrected appropriatly.
Since velocity is a vector you can't manipulate height only. Direction and speed are manipulated as well. Consequently piloting the chopper gets a little sluggish sometimes.