From 000a7093635d7586b9ea3d91048e82a498730a95 Mon Sep 17 00:00:00 2001 From: Eduardo Alvaro Quezada D'Ottone Date: Sat, 18 Jan 2020 14:29:56 -0300 Subject: [PATCH] Gen7 trainer exp multiplier. (#200) * Gen7 trainer exp multiplier. * Changed check for TRAINER_BATTLE_MULTIPLIER from "before Gen 7" to "not Gen 7" as requested. . --- include/constants/battle_config.h | 1 + src/battle_script_commands.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/include/constants/battle_config.h b/include/constants/battle_config.h index 2390bee60b..1480a9cf48 100644 --- a/include/constants/battle_config.h +++ b/include/constants/battle_config.h @@ -53,6 +53,7 @@ #define B_EXP_CATCH GEN_6 // Starting from gen6, pokemon get experience from catching. #define B_ABILITY_POP_UP GEN_6 // Starting from gen5, the pokemon abilities are displayed in a pop-up, when they activate in battle. #define B_STANCE_CHANGE_FAIL GEN_7 // In Gen7, Aegislash's form change does not happen, if the pokemon cannot use a move, because of confusion, paralysis, etc. In gen6, the form change occurs despite not being able to move. +#define B_TRAINER_BATTLE_MULTIPLIER GEN_6 // Gen7 no longer gives a 1.5 multiplier to exp gain. #define B_FAST_INTRO TRUE // If set to TRUE, battle intro texts print at the same time as animation of a pokemon, as opposing to waiting for the animation to end. diff --git a/src/battle_script_commands.c b/src/battle_script_commands.c index ee0913f174..4c3d5baa74 100644 --- a/src/battle_script_commands.c +++ b/src/battle_script_commands.c @@ -3507,7 +3507,7 @@ static void Cmd_getexp(void) gBattleMoveDamage += gExpShareExp; if (holdEffect == HOLD_EFFECT_LUCKY_EGG) gBattleMoveDamage = (gBattleMoveDamage * 150) / 100; - if (gBattleTypeFlags & BATTLE_TYPE_TRAINER) + if (gBattleTypeFlags & BATTLE_TYPE_TRAINER && B_TRAINER_BATTLE_MULTIPLIER != GEN_7) gBattleMoveDamage = (gBattleMoveDamage * 150) / 100; if (IsTradedMon(&gPlayerParty[gBattleStruct->expGetterMonId]))