Fixes to fly_engine script

Many fixes to the 98fly_engine script