Initial Commit After Rewrite

Rewrote entire application. It works, but it really needs some tuning.