diff --git a/avida-core/source/main/cPopulation.cc b/avida-core/source/main/cPopulation.cc index 8b4765198..5b7bb9435 100644 --- a/avida-core/source/main/cPopulation.cc +++ b/avida-core/source/main/cPopulation.cc @@ -1203,7 +1203,12 @@ bool cPopulation::ActivateParasite(cOrganism* host, Systematics::UnitPtr parent, // @TODO - activate parasite target selection should account for hardware type cOrganism* target_organism = NULL; // If there's any migration turned on ... try this first - if(m_world->GetConfig().NUM_DEMES.Get() > 0 && m_world->GetConfig().DEMES_PARASITE_MIGRATION_RATE.Get() > 0.0 && m_world->GetConfig().DEMES_MIGRATION_METHOD.Get() == 4 && m_world->GetRandom().P(m_world->GetConfig().DEMES_PARASITE_MIGRATION_RATE.Get())){ + if( + m_world->GetConfig().NUM_DEMES.Get() > 0 + && m_world->GetConfig().DEMES_PARASITE_MIGRATION_RATE.Get() > 0.0 + && m_world->GetConfig().DEMES_MIGRATION_METHOD.Get() == 4 + && m_world->GetRandom().P(m_world->GetConfig().DEMES_PARASITE_MIGRATION_RATE.Get()) + ){ cDeme& deme = GetDeme(m_world->GetMigrationMatrix().GetProbabilisticDemeID(host_cell.GetDemeID(), m_world->GetRandom(),true)); // Implementation #1 - Picks randomly of ALL cells in to-deme and then finds if the one it chose was occupied