Assorted things

some general things, and stuff, and some things. This actually also has
some bug fixes