Fixed a mistake in the config manager.
Implemented input manager.

This almost finishes #7.