public int MarkCohorts(SpeciesCohorts speciescohort, AgeOnlyCohorts.ISpeciesCohortsDisturbance disturbance)
        {
            Landis.Library.AgeOnlyCohorts.SpeciesCohortBoolArray isSpeciesCohortDamaged = new AgeOnlyCohorts.SpeciesCohortBoolArray();

            isSpeciesCohortDamaged.SetAllFalse(speciescohort.Count);
            disturbance.MarkCohortsForDeath(speciescohort, isSpeciesCohortDamaged);

            //  Go backwards through list of cohort data, so the removal of an
            //  item doesn't mess up the loop.
            int totalReduction = 0;

            for (int i = speciescohort.Count - 1; i >= 0; i--)
            {
                if (isSpeciesCohortDamaged[i])
                {
                    totalReduction += speciescohort[i].Biomass;

                    Landis.Library.BiomassCohorts.Cohort.KilledByAgeOnlyDisturbance(speciescohort, speciescohort[i], disturbance.CurrentSite, disturbance.Type);

                    Cohort.Died(speciescohort, speciescohort[i], disturbance.CurrentSite, disturbance.Type);

                    cohorts.Remove(speciescohort[i]);
                }
            }
            return(totalReduction);
        }
 //---------------------------------------------------------------------
 public void RemoveCohort(Cohort cohort,
                          ActiveSite site,
                          ExtensionType disturbanceType)
 {
     cohorts.Remove(cohort);
     Cohort.Died(this, cohort, site, disturbanceType);
 }
 //---------------------------------------------------------------------
 public void RemoveCohort(int index,
                          ICohort cohort,
                          ActiveSite site,
                          ExtensionType disturbanceType)
 {
     cohorts.RemoveAt(index);
     Cohort.Died(this, cohort, site, disturbanceType);
 }
        public void RemoveCohort(Cohort cohort, Landis.SpatialModeling.ActiveSite site)
        {
            //ResetSpeciesCohorts();
            //Speciescohorts = null;

            cohorts.Remove(cohort);
            Cohort.Died(this, cohort, site, null);
        }
        public int ReduceOrKillBiomassCohorts(Landis.Library.BiomassCohorts.IDisturbance disturbance)
        {
            int totalReduction = 0;

            for (int i = cohorts.Count - 1; i >= 0; i--)
            {
                int reduction = disturbance.ReduceOrKillMarkedCohort(cohorts[i]);
                if (reduction > 0)
                {
                    totalReduction += reduction;
                    if (reduction < cohorts[i].Biomass)
                    {
                        cohorts[i].Wood -= (ushort)reduction;
                    }
                    else
                    {
                        //cohorts[i].IsAlive = false;
                        Cohort.Died(this, cohorts[i], disturbance.CurrentSite, disturbance.Type);
                        cohorts.Remove(cohorts[i]);
                    }
                }
            }
            return(totalReduction);
        }