protected virtual bool Process_Console_Input( string input_string ) { if ( input_string.Length == 0 ) { return false; } if ( input_string[ 0 ] == '/' ) { CUIInputSlashCommandRequest request = new CUIInputSlashCommandRequest( input_string ); Add_Input_Request( request ); return true; } return false; }
private void Handle_Slash_Command_Request( CUIInputSlashCommandRequest request ) { CSlashCommand command = null; string error_string = null; if ( !CSlashCommandParser.Instance.Try_Parse( request, out command, out error_string ) ) { CSharedResource.Output_Text_By_Category( ETextOutputCategory.Error, error_string ); return; } CLog.Log( ELoggingChannel.Logic, ELogLevel.Low, String.Format( "Processing slash command {0}", command.GetType().Name ) ); if ( !CGenericHandlerManager.Instance.Try_Handle( command ) ) { throw new CApplicationException( String.Format( "Encountered an unhandlable slash command: {0}", command.GetType().Name ) ); } }