Lots of improvements

Much more can still be done, but these are a bunch of random things that make it better IMO.