Added jdocs. I'm bad with them so don't be mad if you don't understand any of it.