added and improved a lot