Modified the command interpreter to use the command factory instead of instantiating commands by itself. Closes #45