Added some things, fixed some bugs.