reorganized a bunch of code and cleaned things up a bit