| 6924 | } |
| 6925 | |
| 6926 | void cHardwareExperimental::MakeTopPred(cAvidaContext& ctx) |
| 6927 | { |
| 6928 | if (m_organism->IsPreyFT()) { |
| 6929 | if (m_world->GetConfig().MAX_PRED.Get() && m_world->GetStats().GetNumTotalPredCreatures() >= m_world->GetConfig().MAX_PRED.Get()) m_organism->GetOrgInterface().KillRandPred(ctx, m_organism); |
| 6930 | // switching between predator and prey means having to switch avatar list...don't run this for orgs with AVCell == -1 (avatars off or test cpu) |
| 6931 | if (m_use_avatar && m_organism->GetOrgInterface().GetAVCellID() != -1) { |
| 6932 | m_organism->GetOrgInterface().SwitchPredPrey(ctx); |
| 6933 | m_organism->SetTopPredFT(ctx); |
| 6934 | } |
| 6935 | else m_organism->SetTopPredFT(ctx); |
| 6936 | } |
| 6937 | else if (m_organism->IsPredFT()) m_organism->SetTopPredFT(ctx); |
| 6938 | } |
| 6939 | |
| 6940 | bool cHardwareExperimental::TestAttack(cAvidaContext& ctx) |
| 6941 | { |
nothing calls this directly
no test coverage detected