From 66764513530aefc06427ed23ea7fab6ef23df028 Mon Sep 17 00:00:00 2001 From: Eduardo Quezada Date: Sat, 17 Oct 2020 01:52:14 -0300 Subject: [PATCH] Net ball modifier in config --- include/constants/item_config.h | 3 +++ src/battle_script_commands.c | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/include/constants/item_config.h b/include/constants/item_config.h index 018efcff7..410623cdf 100644 --- a/include/constants/item_config.h +++ b/include/constants/item_config.h @@ -17,7 +17,10 @@ #define P_SHINY_CHARM_REROLLS 3 // Amount of re-rolls if the player has the Shiny Charm. Set to 0 to disable Shiny Charm's effects. #define P_KEY_FOSSILS GEN_7 // In Gen4+, all Gen 3 fossils became regular items. #define P_KEY_ESCAPE_ROPE GEN_7 // In Gen8, Escape Rope became a Key Item. + +// Ball config #define P_LURE_BALL_MODIFIER GEN_7 // In Gen7+, Lure Ball's catch multiplier is x5 instead of x3. #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. #endif // GUARD_CONSTANTS_ITEM_CONFIG_H diff --git a/src/battle_script_commands.c b/src/battle_script_commands.c index 5b3d97fcb..5ec8eb434 100644 --- a/src/battle_script_commands.c +++ b/src/battle_script_commands.c @@ -9786,7 +9786,11 @@ static void Cmd_handleballthrow(void) { case ITEM_NET_BALL: if (IS_BATTLER_OF_TYPE(gBattlerTarget, TYPE_WATER) || IS_BATTLER_OF_TYPE(gBattlerTarget, TYPE_BUG)) - ballMultiplier = 30; + #if P_NET_BALL_MODIFIER >= GEN_7 + ballMultiplier = 50; + #else + ballMultiplier = 30; + #endif break; case ITEM_DIVE_BALL: if (GetCurrentMapType() == MAP_TYPE_UNDERWATER)