Pulled the code apart into separate packages; hopefully this means that someone other than me can make sense of my spaghetti code :)