From 32a2f91ecb9b06a5190808bf7535b880f2fb48d9 Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Sat, 17 Oct 2020 02:04:39 -0300 Subject: [PATCH] Repeat Ball modifier in config. --- include/constants/item_config.h | 1 + src/battle_script_commands.c | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/include/constants/item_config.h b/include/constants/item_config.h index 3a5ebfaa85..eacad0af30 100644 --- a/include/constants/item_config.h +++ b/include/constants/item_config.h @@ -23,5 +23,6 @@ #define P_HEAVY_BALL_MODIFIER GEN_7 // In Gen7+, Heavy Ball's ranges change. See Cmd_handleballthrow. #define P_NET_BALL_MODIFIER GEN_7 // In Gen7+, Net Ball's catch multiplier is x5 instead of x3. #define P_NEST_BALL_MODIFIER GEN_7 // Nest Ball's formula varies depending on the Gen. See Cmd_handleballthrow. +#define P_REPEAT_BALL_MODIFIER GEN_7 // In Gen7+, Net Ball's catch multiplier is x3.5 instead of x3. #endif // GUARD_CONSTANTS_ITEM_CONFIG_H diff --git a/src/battle_script_commands.c b/src/battle_script_commands.c index 3a13ffeebd..6f07c6bca3 100644 --- a/src/battle_script_commands.c +++ b/src/battle_script_commands.c @@ -9817,7 +9817,11 @@ static void Cmd_handleballthrow(void) break; case ITEM_REPEAT_BALL: if (GetSetPokedexFlag(SpeciesToNationalPokedexNum(gBattleMons[gBattlerTarget].species), FLAG_GET_CAUGHT)) - ballMultiplier = 30; + #if P_REPEAT_BALL_MODIFIER >= GEN_7 + ballMultiplier = 35; + #else + ballMultiplier = 30; + #endif break; case ITEM_TIMER_BALL: ballMultiplier = gBattleResults.battleTurnCounter + 10;