added readme, fixed a few bugs