From e9c6c96b9d087103b88e84e891186336e3d9359a Mon Sep 17 00:00:00 2001 From: LOuroboros Date: Sat, 12 Dec 2020 11:54:41 -0300 Subject: [PATCH 1/3] Corrected Final Gambit's move data It didn't have its own working effect assigned, and it wasn't being affected by King's Rock even though it should. --- src/data/battle_moves.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/data/battle_moves.h b/src/data/battle_moves.h index 0b0c0b5530..bce0c60e5d 100644 --- a/src/data/battle_moves.h +++ b/src/data/battle_moves.h @@ -7986,7 +7986,7 @@ const struct BattleMove gBattleMoves[MOVES_COUNT] = [MOVE_FINAL_GAMBIT] = { - .effect = EFFECT_HIT_SWITCH_TARGET, + .effect = EFFECT_FINAL_GAMBIT, .power = 1, .type = TYPE_FIGHTING, .accuracy = 100, @@ -7994,7 +7994,7 @@ const struct BattleMove gBattleMoves[MOVES_COUNT] = .secondaryEffectChance = 0, .target = MOVE_TARGET_SELECTED, .priority = 0, - .flags = FLAG_PROTECT_AFFECTED, + .flags = FLAG_PROTECT_AFFECTED | FLAG_KINGSROCK_AFFECTED, .split = SPLIT_SPECIAL, }, From 9f2dc914ba1064bf9085a52c6daf3b77885db61f Mon Sep 17 00:00:00 2001 From: LOuroboros Date: Sat, 19 Dec 2020 21:57:47 -0300 Subject: [PATCH 2/3] Tweaked Final Gambit's effect -Made the user faint before the foe like in the official games -Removed calls to resultmessage and critmessage as those were never needed by this move's effect --- data/battle_scripts_1.s | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/data/battle_scripts_1.s b/data/battle_scripts_1.s index 0ccaa7ef64..8065073fcd 100644 --- a/data/battle_scripts_1.s +++ b/data/battle_scripts_1.s @@ -1082,16 +1082,12 @@ BattleScript_EffectFinalGambit: waitstate healthbarupdate BS_TARGET datahpupdate BS_TARGET - critmessage - waitmessage 0x40 - resultmessage - waitmessage 0x40 - seteffectwithchance - tryfaintmon BS_TARGET, FALSE, NULL - jumpifmovehadnoeffect BattleScript_MoveEnd healthbarupdate BS_ATTACKER datahpupdate BS_ATTACKER + seteffectwithchance tryfaintmon BS_ATTACKER, FALSE, NULL + tryfaintmon BS_TARGET, FALSE, NULL + jumpifmovehadnoeffect BattleScript_MoveEnd goto BattleScript_MoveEnd BattleScript_EffectHitSwitchTarget: From 3918542b3e10a441344fb70ac7411b3dbcc55ce3 Mon Sep 17 00:00:00 2001 From: LOuroboros Date: Sun, 20 Dec 2020 21:31:36 -0300 Subject: [PATCH 3/3] Corrections to Final Gambit's effect's battle script -Restored the call to resultmessage -Corrected its behavior against Endured, Focus Banded/Sashed and Sturdy foes --- data/battle_scripts_1.s | 3 +++ 1 file changed, 3 insertions(+) diff --git a/data/battle_scripts_1.s b/data/battle_scripts_1.s index 8065073fcd..0856324e2d 100644 --- a/data/battle_scripts_1.s +++ b/data/battle_scripts_1.s @@ -1082,6 +1082,9 @@ BattleScript_EffectFinalGambit: waitstate healthbarupdate BS_TARGET datahpupdate BS_TARGET + resultmessage + waitmessage 0x40 + dmgtocurrattackerhp healthbarupdate BS_ATTACKER datahpupdate BS_ATTACKER seteffectwithchance