Removed some old files, did some documentation of the API, and some stuff to hopefully avoid crashes.