Added affection effects

This commit is contained in:
Maruno17
2021-10-31 20:43:16 +00:00
parent ee16c22388
commit 0ec67f78fa
11 changed files with 187 additions and 61 deletions

View File

@@ -152,6 +152,11 @@ class PokeBattle_Battle
i = BattleHandlers.triggerExpGainModifierItem(@initialItems[0][idxParty],pkmn,exp)
end
exp = i if i>=0
# Boost Exp gained with high affection
if Settings::AFFECTION_EFFECTS && @internalBattle && pkmn.affection_level >= 4 && !pkmn.mega?
exp = exp * 6 / 5
isOutsider = true # To show the "boosted Exp" message
end
# Make sure Exp doesn't exceed the maximum
expFinal = growth_rate.add_exp(pkmn.exp, exp)
expGained = expFinal-pkmn.exp