Added the base functionality for executing commands in UI and GameEngine.

For now only 'exit' and 'restart' work.