Improved function manualControlPygame