diff --git a/test/test_runner_battle.c b/test/test_runner_battle.c index ec7ba275c..524525c13 100644 --- a/test/test_runner_battle.c +++ b/test/test_runner_battle.c @@ -933,9 +933,11 @@ void Ability_(u32 sourceLine, u32 ability) void Level_(u32 sourceLine, u32 level) { // TODO: Preserve any explicitly-set stats. + u32 species = GetMonData(DATA.currentMon, MON_DATA_SPECIES); INVALID_IF(!DATA.currentMon, "Level outside of PLAYER/OPPONENT"); INVALID_IF(level == 0 || level > MAX_LEVEL, "Illegal level: %d", level); SetMonData(DATA.currentMon, MON_DATA_LEVEL, &level); + SetMonData(DATA.currentMon, MON_DATA_EXP, &gExperienceTables[gSpeciesInfo[species].growthRate][level]); } void MaxHP_(u32 sourceLine, u32 maxHP)