added a few changes. it's almost done