added most of the stuff