예제 #1
0
파일: StatBin.cs 프로젝트: yakoder/NRaas
 public void IncStat(string stat, Common.DebugLevel minLevel)
 {
     if (DebuggingLevel >= minLevel)
     {
         IncStat(stat);
     }
 }
예제 #2
0
        public int AddScoring(string stat, int score, Common.DebugLevel minLevel)
        {
            if (!Common.kDebugging)
            {
                return(score);
            }

            if (!string.IsNullOrEmpty(stat))
            {
                stat = ": " + stat;
            }

            if ((Scenarios != null) && (Scenarios.TrackingID == ID))
            {
                Scenarios.Trace = true;
                try
                {
                    Scenarios.AddScoring(GetIDName() + stat, score, minLevel);
                }
                finally
                {
                    Scenarios.Trace = false;
                }
            }

            return(Manager.AddScoring(UnlocalizedName + stat, score, minLevel));
        }
예제 #3
0
 public void SetDebuggingLevel(Common.DebugLevel value)
 {
     if (mDebugLevel != null)
     {
         mDebugLevel.SetValue(value);
     }
 }
예제 #4
0
        public void IncStat(string stat, Common.DebugLevel minLevel)
        {
            if (!Common.kDebugging)
            {
                return;
            }

            if ((Scenarios != null) && (Scenarios.TrackingID == ID))
            {
                Scenarios.Trace = true;
                try
                {
                    Scenarios.IncStat(GetIDName() + ": " + stat, minLevel);
                }
                finally
                {
                    Scenarios.Trace = false;
                }
            }

            if (Manager != null)
            {
                Manager.IncStat(UnlocalizedName + ": " + stat, minLevel);
            }
        }
예제 #5
0
        public override float AddStat(string stat, float val, Common.DebugLevel minLevel)
        {
            if (!Common.kDebugging)
            {
                return(val);
            }

            if ((DebuggingEnabled) && (mTotalStats != null))
            {
                mTotalStats.AddStat(stat, val);
            }

            if ((minLevel == Common.DebugLevel.High) && (mStats != null) && (DebuggingLevel >= minLevel))
            {
                SimpleMessageDialog.Show(UnlocalizedName, stat);
                minLevel = Common.DebugLevel.Low;
            }

            if ((mStats != null) && (DebuggingLevel >= minLevel))
            {
                mStats.AddStat(stat, val);
            }

            return(val);
        }
예제 #6
0
파일: StatBin.cs 프로젝트: yakoder/NRaas
 public int AddScoring(string stat, int score, Common.DebugLevel minLevel)
 {
     if (DebuggingLevel >= minLevel)
     {
         AddScoring(stat, (float)score);
     }
     return(score);
 }
예제 #7
0
            protected override bool Allow(Common.DebugLevel value)
            {
                if (value == Common.DebugLevel.Logging)
                {
                    return(false);
                }

                return(base.Allow(value));
            }
예제 #8
0
        public int AddStat(string stat, int val, Common.DebugLevel minLevel)
        {
            if (!Common.kDebugging)
            {
                return(val);
            }

            return((int)AddStat(stat, (float)val, minLevel));
        }
예제 #9
0
        public static float AddStat(string stat, float val, Common.DebugLevel minLevel)
        {
            if (sStats == null)
            {
                return(val);
            }

            return(sStats.AddStat(stat, val, minLevel));
        }
예제 #10
0
        public override void IncStat(string stat, Common.DebugLevel minLevel)
        {
            if (mTrack)
            {
                Track(stat);
            }

            base.IncStat(stat, minLevel);
        }
예제 #11
0
        public override float AddStat(string stat, float val, Common.DebugLevel minLevel)
        {
            if (mTrack)
            {
                Track(stat + " (" + val + ")");
            }

            return(base.AddStat(stat, val, minLevel));
        }
예제 #12
0
        public static void IncStat(string stat, Common.DebugLevel minLevel)
        {
            if (sStats == null)
            {
                return;
            }

            sStats.IncStat(stat, minLevel);
        }
예제 #13
0
            public int AddScoring(string stat, int score, Common.DebugLevel minLevel)
            {
                if (!Common.kDebugging)
                {
                    return(score);
                }

                return(mStats.AddScoring(mName + " " + stat, score, minLevel));
            }
예제 #14
0
파일: StatBin.cs 프로젝트: yakoder/NRaas
        public int AddStat(string stat, int val, Common.DebugLevel minLevel)
        {
            if (DebuggingLevel >= minLevel)
            {
                AddStat(stat, val);
            }

            return(val);
        }
예제 #15
0
            public void IncStat(string stat, Common.DebugLevel minLevel)
            {
                if (!Common.kDebugging)
                {
                    return;
                }

                mStats.IncStat(mName + " " + stat, minLevel);
            }
예제 #16
0
            public float AddStat(string stat, float val, Common.DebugLevel minLevel)
            {
                if (!Common.kDebugging)
                {
                    return(val);
                }

                return(mStats.AddStat(mName + " " + stat, val, minLevel));
            }
예제 #17
0
            public int AddScoring(string scoring, SimDescription sim, Common.DebugLevel minLevel)
            {
                int score = ScoringLookup.GetScore(scoring, sim);

                if (!Common.kDebugging)
                {
                    return(score);
                }

                return(AddScoring(mName + " " + scoring, score, minLevel));
            }
예제 #18
0
        public float AddStat(string stat, float val, Common.DebugLevel minLevel)
        {
            if (!Common.kDebugging)
            {
                return(val);
            }

            if ((Scenarios != null) && (Scenarios.TrackingID == ID))
            {
                Scenarios.Trace = true;
                try
                {
                    Scenarios.AddStat(GetIDName() + ": " + stat, val, minLevel);
                }
                finally
                {
                    Scenarios.Trace = false;
                }
            }

            return(Manager.AddStat(UnlocalizedName + ": " + stat, val, minLevel));
        }
예제 #19
0
        public int AddScoring(string stat, int score, Common.DebugLevel minLevel)
        {
            if (!Common.kDebugging)
            {
                return(score);
            }

            if (score > 0)
            {
                AddStat(stat + " Scoring Pos", score, minLevel);
            }
            else if (score < 0)
            {
                AddStat(stat + " Scoring Neg", score, minLevel);
            }
            else
            {
                AddStat(stat + " Scoring Zero", score, minLevel);
            }

            return(score);
        }
예제 #20
0
        public override void IncStat(string stat, Common.DebugLevel minLevel)
        {
            if (!Common.kDebugging)
            {
                return;
            }

            if ((DebuggingEnabled) && (mTotalStats != null))
            {
                mTotalStats.IncStat(stat);
            }

            if ((minLevel == Common.DebugLevel.High) && (mStats != null) && (DebuggingLevel >= minLevel))
            {
                Common.Notify(stat);

                minLevel = Common.DebugLevel.Low;
            }

            if ((mStats != null) && (DebuggingLevel >= minLevel))
            {
                mStats.IncStat(stat);
            }
        }
예제 #21
0
 public int AddScoring(string scoring, SimDescription sim, Common.DebugLevel minLevel)
 {
     return(AddScoring(scoring, ScoringLookup.GetScore(scoring, sim)));
 }
예제 #22
0
 public void IncStat(string stat, Common.DebugLevel minLevel)
 {
     sStats.IncStat(stat);
 }
예제 #23
0
 public float AddStat(string stat, float val, Common.DebugLevel minLevel)
 {
     return(sStats.AddStat(stat, val));
 }
예제 #24
0
 public int AddStat(string stat, int val, Common.DebugLevel minLevel)
 {
     return((int)sStats.AddStat(stat, val));
 }
예제 #25
0
 public int AddScoring(string stat, int score, Common.DebugLevel minLevel)
 {
     return((int)sStats.AddScoring(stat, score));
 }
예제 #26
0
 public void IncStat(string stat, Common.DebugLevel minLevel)
 {
     mManager.IncStat(stat, minLevel);
     mResult = stat;
 }
예제 #27
0
 public int AddStat(string stat, int val, Common.DebugLevel minLevel)
 {
     mResult = stat + ": " + val;
     return(mManager.AddStat(stat, val, minLevel));
 }
예제 #28
0
 public int AddScoring(string stat, int score, Common.DebugLevel minLevel)
 {
     mResult = stat + ": " + score;
     return(mManager.AddScoring(stat, score, minLevel));
 }
예제 #29
0
 public int AddScoring(string scoring, int option, ScoringLookup.OptionType type, SimDescription sim, SimDescription other, Common.DebugLevel minLevel)
 {
     return(AddScoring(scoring, ScoringLookup.GetScore(scoring, option, type, sim, other), minLevel));
 }
예제 #30
0
 public float AddStat(string stat, float val, Common.DebugLevel minLevel)
 {
     mEntry.Add(val);
     return(val);
 }