コード例 #1
0
        public Achievement(string name, string description, string shortDescription, AchievementProgression achievementProgression, int points)
        {
            Ensure.NotNullOrWhitespace(name);
            Ensure.NotNull(achievementProgression); // a bit meh...

            this.Name = name;
            this.Description = description ?? "";
            this.ShortDescription = shortDescription ?? description;
            this.Progression = achievementProgression;
            this.Points = points;

            this.Progression.Unlocked += () => this.Unlocked.InvokeIfNotNull();
        }
コード例 #2
0
 public Achievement(string name, string description, AchievementProgression achievementProgression, int points)
     : this(name, description, null, achievementProgression, points)
 {
 }
コード例 #3
0
 public Achievement(string name, string description, string shortDescription, AchievementProgression achievementProgression)
     : this(name, description, shortDescription, achievementProgression, 0)
 {
 }