Пример #1
0
 public ChallengeResult(PlanetChallenge pc, bool passed)
 {
     pointresult  = new List <PointResult>();
     theChallenge = pc;
     for (int i = 0; i < pc.Difficulty; i++)
     {
         pointresult.Add((passed) ? PointResult.Passed : PointResult.Failed);
     }
 }
Пример #2
0
        public ChallengeResult(PlanetChallenge pc, int statcount, int luck)
        {
            theChallenge = pc;
            pointresult  = new List <PointResult>();
            int i = 0;

            for (i = 0; i < statcount; i++)
            {
                pointresult.Add(PointResult.Passed);
            }
            for (; i < pc.Difficulty; i++)
            {
                if (luck > 0)
                {
                    luck--;
                    pointresult.Add(PointResult.Lucky);
                }
                else
                {
                    pointresult.Add(PointResult.Failed);
                }
            }
        }