diff --git a/src/Battling/Library/ExperienceLibrary.cpp b/src/Battling/Library/ExperienceLibrary.cpp index bdddf98..3a7b3e9 100644 --- a/src/Battling/Library/ExperienceLibrary.cpp +++ b/src/Battling/Library/ExperienceLibrary.cpp @@ -14,6 +14,8 @@ void PkmnLib::Battling::ExperienceLibrary::HandleExperienceGain( auto v1 = (expGain * level) / 5; for (auto op : opponents) { + if (!op->AllowedExperienceGain()) + continue; auto v2 = pow(2 * level + 10, 2.5) / pow(level + op->GetLevel() + 10, 2.5); uint32_t experienceGain = v1 * v2 + 1; // TODO: Check owner and international