updating selection logic to use coroutines

regrettably also did some feature adding, refactoring, and file
reorganization

niiiice
amending missed changes to 4a68206

i dunno why my client didn't git them before