예제 #1
0
파일: Choice.cs 프로젝트: zombisaur/iggy
        public Choice(SelectRule rule, Character character)
        {
            this.rule = rule;
            this.character = character;
            this.options = new ObservableCollection<RuleElement>();

            FillItems();
            if (this.rule.Filter != null)
            {
                this.rule.Filter.FilterChanged += OnFilterChanged;
            }
        }
예제 #2
0
파일: Rule.cs 프로젝트: zombisaur/iggy
 public abstract void Revoke(Character character);
예제 #3
0
 protected override void UnbindCharacter(Character character)
 {
     this.boundStat.PropertyChanged -= OnBoundStatPropertyChanged;
     this.boundStat = null;
 }
예제 #4
0
 protected override void UnbindCharacter(Character character)
 {
     this.baseRule.UnbindCharacter(character);
 }
예제 #5
0
 protected abstract void UnbindCharacter(Character character);
예제 #6
0
 public override sealed void Apply(Character character)
 {
     character.GetStat(Stat).AddModifier(this);
     BindCharacter(character);
 }
예제 #7
0
 public override void Apply(Character character)
 {
     character.TextStrings[this.name] = this.value;
 }
예제 #8
0
파일: GrantRule.cs 프로젝트: zombisaur/iggy
 public override void Revoke(Character character)
 {
     character.Revoke(this.element);
 }
예제 #9
0
 public void Apply(Character character)
 {
     foreach (Rule rule in this.rules) { rule.Apply(character); }
 }
예제 #10
0
 public override void Revoke(Character character)
 {
     /// TODO: Errrr... maybe?
 }
예제 #11
0
파일: GrantRule.cs 프로젝트: zombisaur/iggy
 public override void Apply(Character character)
 {
     character.Grant(this.element);
 }
예제 #12
0
 public override void Apply(Character character)
 {
     character.Alias(this.name, this.alias);
 }
예제 #13
0
 public void Unbind(Character character)
 {
     this.character.Inventory.PropertyChanged -= InventoryPropertyChanged;
     this.character = null;
 }
예제 #14
0
 public void Bind(Character character)
 {
     this.character = character;
     this.character.Inventory.PropertyChanged += InventoryPropertyChanged;
 }
예제 #15
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
 public override bool Check(Character character)
 {
     return character.Grants.Contains(this.boundElement);
 }
예제 #16
0
 public void Revoke(Character character)
 {
     foreach (Rule rule in this.rules) { rule.Revoke(character); }
 }
예제 #17
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
 public abstract bool Check(Character character);
예제 #18
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
 public override bool Check(Character character)
 {
     return this.left.Check(character) && this.right.Check(character);
 }
예제 #19
0
 public override void Revoke(Character character)
 {
     character.TextStrings.Remove(this.name);
 }
예제 #20
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
 public override bool Check(Character character)
 {
     int required = this.count;
     for (int i = 0; i < prereqs.Length && required > 0; i++)
     {
         if (this.prereqs[i].Check(character)) { required--; }
     }
     return (required == 0);
 }
예제 #21
0
 public override void Revoke(Character character)
 {
     throw new NotImplementedException();
 }
예제 #22
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
 public override bool Check(Character character)
 {
     return false;
 }
예제 #23
0
 public override sealed void Revoke(Character character)
 {
     UnbindCharacter(character);
     character.GetStat(Stat).RemoveModifier(this);
 }
예제 #24
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
 public override bool Check(Character character)
 {
     return !this.prereq.Check(character);
 }
예제 #25
0
 protected override void UnbindCharacter(Character character)
 {
 }
예제 #26
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
 public override bool Check(Character character)
 {
     throw new NotImplementedException();
 }
예제 #27
0
 protected override void BindCharacter(Character character)
 {
     this.boundStat = character.GetStat(this.sourceStat);
     this.boundStat.PropertyChanged += OnBoundStatPropertyChanged;
 }
예제 #28
0
파일: Prereq.cs 프로젝트: zombisaur/iggy
            public override bool Check(Character character)
            {
                for (int i = 0; i < this.boundElements.Length; i++)
                {
                    if (character.Grants.Contains(this.boundElements[i])) { return true; }
                }

                 	            return false;
            }
예제 #29
0
 protected override void UnbindCharacter(Character character)
 {
     this.predicate.Unbind(character);
     base.UnbindCharacter(character);
 }
예제 #30
0
파일: Rule.cs 프로젝트: zombisaur/iggy
 public abstract void Apply(Character character);