I made a altitude holding PID controler for kFS.
I have never really done control systems programing so this was a bit of an adventure. Currently I have a vertical speed limiting if statement which seems to prevent excessive overshooting. It works okay on earth but not as well as on the moon...