Major refactor

Cleaned and simplified. Much nicer on the eyes, and a little nicer on
the CPU.