Input/Output code moved to dedicated module

First step in attempting to distance game code from being irc specific.
This should also make testing much easier.