Added some stuff, fixed some bugs