implemented defineConsoleCommand
changed the defineConsoleCommand function to a consoleCommand object