Rewrote a lot of stuff for a _much_ cleaner architecture.