numerous improvements

and less breaking of important stuff