Implements experience gain
Build / Build (push) Successful in 1m49s

This commit is contained in:
Deukhoofd committed 2025-11-02 23:20:07 +01:00
1 parent f00453448f
commit 90eaeb1a72
7 files changed
+83 -2

No files matched your search

+5
View File
@@ -1184,6 +1184,11 @@ public class PokemonImpl : ScriptSource, IPokemon
BattleData.BattleSide.MarkFaint(BattleData.Position);
BattleData.BattleSide.ForceClearPokemonFromField(BattleData.Position);
foreach (var opponent in BattleData.SeenOpponents.WhereNotNull())
{
opponent.AddExperience(Library.ExperienceGainCalculator.CalculateExperienceGain(this, opponent));
}
// Validate the battle state to see if the battle is over.
BattleData.Battle.ValidateBattleState();
}