protected override void ManageFormationCounts()
 {
     this.ManageFormationCounts(1, 1, 1, 1);
     this._mainInfantry = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsInfantryFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
     if (this._mainInfantry != null)
     {
         this._mainInfantry.AI.IsMainFormation = true;
     }
     this._archers       = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsRangedFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
     this._cavalry       = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsCavalryFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
     this._rangedCavalry = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsRangedCavalryFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
 }
 protected override void ManageFormationCounts()
 {
     if (this._weaponsToBeDefendedState == TacticSallyOutDefense.WeaponsToBeDefended.TwoPrimary)
     {
         this.ManageFormationCounts(1, 1, 1, 1);
         this._mainInfantry = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsInfantryFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
         if (this._mainInfantry != null)
         {
             this._mainInfantry.AI.IsMainFormation = true;
         }
         this._archers          = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsRangedFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
         this._cavalryFormation = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsCavalryFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
         this._rangedCavalry    = TacticComponent.ChooseAndSortByPriority(this.Formations, (Func <Formation, bool>)(f => f.QuerySystem.IsRangedCavalryFormation), (Func <Formation, bool>)(f => f.IsAIControlled), (Func <Formation, float>)(f => f.QuerySystem.FormationPower)).FirstOrDefault <Formation>();
     }
     else
     {
         this.AssignTacticFormations1121();
     }
 }