basically started over with code from omar