Fixed a bunch of stuff

Can't remember what.