Added better documentation and such