lots of work. some functionality