public void SendCommand(string commandName) { var command = commandList.FindCommand(commandName); if (command != null) { command.Execute(); } else { WriteLine("Command not found"); } inputText.text = ""; }