public override void ApplyEffectKind(Person person, Event e)
 {
     int index = person.Tags.IndexOf(tag + ",");
     if (index >= 0) {
         person.Tags.Remove(index, tag.Length + 2);
     }
 }
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFactionWithPrincess != null)
     {
         person.AddHated(person.BelongedFaction.Leader);
     }
 }
Пример #3
0
        public override void ApplyEffectKind(Person person, Event e)
        {
            Title title = person.Scenario.GameCommonData.AllTitles.GetTitle(increment);
            if (title == null) return;

            person.LearnTitle(title);
        }
Пример #4
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.LocationArchitecture != null)
     {
         Captive captive = Captive.Create(base.Scenario, person, person.LocationArchitecture.BelongedFaction);
     }
 }
Пример #5
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFaction != null && person.BelongedFaction.Leader != person)
     {
         person.Loyalty += increment;
     }
 }
Пример #6
0
 public bool CheckCondition(Architecture architecture, Event e)
 {
     if (this.Kind == null) return false;
     this.Kind.InitializeParameter(this.Parameter);
     this.Kind.InitializeParameter2(this.Parameter2);
     return this.Kind.CheckConditionKind(architecture, e) || this.Kind.CheckConditionKind(architecture);
 }
Пример #7
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFaction != null)
     {
         person.ClosePersons.Add(person.BelongedFaction.LeaderID);
     }
 }
Пример #8
0
 public override void ApplyEffectKind(Architecture a, Event e)
 {
     foreach (Military i in a.Militaries)
     {
         i.IncreaseQuantity(increment);
     }
 }
Пример #9
0
 public bool CheckCondition(Person person, Event e)
 {
     if (this.Kind == null) return false;
     this.Kind.InitializeParameter(this.Parameter);
     this.Kind.InitializeParameter2(this.Parameter2);
     return this.Kind.CheckConditionKind(person, e) || this.Kind.CheckConditionKind(person);
 }
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFactionWithPrincess != null)
     {
         person.BelongedFactionWithPrincess.Leader.AdjustRelation(person, 0, increment);
     }
 }
Пример #11
0
 public override void ApplyEffectKind(Architecture a, Event e)
 {
     while (a.Facilities.Count > 0)
     {
         a.DemolishFacility(a.Facilities[0] as Facility);
     }
 }
Пример #12
0
 public virtual void ApplyEffectKind(Architecture architecture, Event e)
 {
     foreach (Person p in architecture.Persons)
     {
         this.ApplyEffectKind(p, e);
     }
 }
Пример #13
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.LocationArchitecture != null)
     {
         person.Status = GameObjects.PersonDetail.PersonStatus.Princess;
     }
 }
Пример #14
0
 public bool CheckCondition(Troop troop, Event e)
 {
     if (this.Kind == null) return false;
     this.Kind.InitializeParameter(this.Parameter);
     this.Kind.InitializeParameter2(this.Parameter2);
     return this.Kind.CheckConditionKind(troop, e) || this.Kind.CheckConditionKind(troop);
 }
Пример #15
0
 public override void ApplyEffectKind(Faction f, Event e)
 {
     GameObjectList d = base.Scenario.DiplomaticRelations.GetDiplomaticRelationListByFactionID(f.ID);
     foreach (GameObjects.FactionDetail.DiplomaticRelation i in d)
     {
         i.Relation += increment;
     }
 }
Пример #16
0
 public virtual bool CheckConditionKind(Architecture architecture, Event e)
 {
     if (this.ID >= 3000 && this.ID < 4000)
     {
         return architecture.BelongedFaction != null && this.CheckConditionKind(architecture.BelongedFaction, e);
     }
     return false;
 }
Пример #17
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.LocationArchitecture != null && person.Status == GameObjects.PersonDetail.PersonStatus.Princess)
     {
         Architecture originalLocationArch = person.LocationArchitecture;
         person.Status = GameObjects.PersonDetail.PersonStatus.Normal;
     }
 }
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFaction != null && person.LocationArchitecture != null && person.BelongedCaptive == null)
     {
         PersonGeneratorType type = person.Scenario.GameCommonData.AllPersonGeneratorTypes[preferredType] as PersonGeneratorType;
         person.LocationArchitecture.GenerateOfficer(type,true);
     }
 }
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFactionWithPrincess != null)
     {
         person.BelongedFaction.Leader.Spouse = person;
         person.Spouse = person.BelongedFaction.Leader;
     }
 }
Пример #20
0
 public virtual bool CheckConditionKind(Troop troop, Event e)
 {
     if (this.ID >= 3000 && this.ID < 4000)
     {
         return troop.BelongedFaction != null && this.CheckConditionKind(troop.BelongedFaction, e);
     }
     return false;
 }
Пример #21
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFaction != null)
     {
         person.Brothers.Add(person.BelongedFaction.Leader);
         person.BelongedFaction.Leader.Brothers.Add(person);
     }
 }
Пример #22
0
 public override void ApplyEffectKind(Faction f, Event e)
 {
     GameObjects.FactionDetail.Technique technique = f.Scenario.GameCommonData.AllTechniques.GetTechnique(increment);
     f.AvailableTechniques.AddTechnique(technique);
     f.Scenario.NewInfluence = true;
     technique.Influences.ApplyInfluence(f, GameObjects.Influences.Applier.Technique, increment);
     f.Scenario.NewInfluence = false;
 }
 public override void ApplyEffectKind(Person person, Event e)
 {
     if (person.BelongedFaction != null)
     {
         person.BelongedFaction.Leader.Spouse = person.ID;
         person.Spouse = person.BelongedFaction.Leader.ID;
     }
 }
Пример #24
0
 public override void ApplyEffectKind(Architecture a, Event e)
 {
     a.zainan.shengyutianshu += id;
     if (a.zainan.shengyutianshu <= 0)
     {
         a.youzainan = false;
         a.tingzhizhenzai();
     }
 }
Пример #25
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     Treasure t = person.Scenario.Treasures.GetGameObject(type) as Treasure;
     if (t.BelongedPerson != null)
     {
         t.BelongedPerson.LoseTreasure(t);
     }
     person.ReceiveTreasure(t);
 }
Пример #26
0
 public override void ApplyEffectKind(Architecture a, Event e)
 {
     a.zainan.zainanzhonglei = base.Scenario.GameCommonData.suoyouzainanzhonglei.Getzainanzhonglei(id);
     a.zainan.shengyutianshu = a.zainan.zainanzhonglei.shijianxiaxian + GameObject.Random(a.zainan.zainanzhonglei.shijianshangxian - a.zainan.zainanzhonglei.shijianxiaxian);
     a.youzainan = true;
     foreach (Military military in a.Militaries)//发生灾难时不能补充
     {
         military.StopRecruitment();
     }
 }
Пример #27
0
        public override void ApplyEffectKind(Person person, Event e)
        {
            GameObjects.PersonDetail.Title title = person.Scenario.GameCommonData.AllTitles.GetTitle(increment);

            if (person.RealTitles.Contains(title))
            {
                title.Influences.PurifyInfluence(person, GameObjects.Influences.Applier.Title, title.ID);
                person.RealTitles.Remove(title);
            }
        }
Пример #28
0
 public override void ApplyEffectKind(Person person, Event e)
 {
     Treasure t = person.Scenario.Treasures.GetGameObject(type) as Treasure;
     if (t.BelongedPerson != null && t.BelongedPerson == person)
     {
         person.LoseTreasure(t);
         t.Available = false;
         t.HidePlace = person.Scenario.Architectures.GameObjects[GameObject.Random(person.Scenario.Architectures.GameObjects.Count)] as Architecture;
     }
 }
Пример #29
0
 public override void ApplyEffectKind(Architecture a, Event e)
 {
     foreach (Military i in a.Militaries)
     {
         if (i.KindID == mType)
         {
             i.IncreaseCombativity(increment);
         }
     }
 }
Пример #30
0
 public override void ApplyEffectKind(Architecture a, Event e)
 {
     foreach (Facility f in a.Facilities)
     {
         if (f.KindID == id)
         {
             a.DemolishFacility(f);
             return;
         }
     }
 }