Fix incrementing.
Remove dead code.

There was a bunch of dead code that could easily be removed, so why not.