Beispiel #1
0
        public void Error(string format, params object[] args)
        {
            Log.ErrorFormat(format, args);

            var logArgs = new SharpStarLogEventArgs(LogType.Error, string.Format(format, args));

            if (AllLogOutput != null)
            {
                AllLogOutput(this, logArgs);
            }

            if (LogOutput != null)
            {
                LogOutput(this, logArgs);
            }
        }
Beispiel #2
0
        public void Debug(string format, params object[] args)
        {
            if (StarMain.Instance.ServerConfig.EnableDebugLog)
            {
                Log.DebugFormat(format, args);
            }

            var logArgs = new SharpStarLogEventArgs(LogType.Debug, string.Format(format, args));

            if (AllLogOutput != null)
            {
                AllLogOutput(this, logArgs);
            }

            if (LogOutput != null)
            {
                LogOutput(this, logArgs);
            }
        }