Implemented Dire Claw's effect

This commit is contained in:
LOuroboros 2022-12-13 02:19:41 -03:00
parent 3ce4869766
commit 2cb9400ef0
5 changed files with 27 additions and 4 deletions

View File

@ -418,6 +418,11 @@ gBattleScriptsForMoveEffects::
.4byte BattleScript_EffectVictoryDance @ EFFECT_VICTORY_DANCE .4byte BattleScript_EffectVictoryDance @ EFFECT_VICTORY_DANCE
.4byte BattleScript_EffectCeaselessEdge @ EFFECT_CEASELESS_EDGE .4byte BattleScript_EffectCeaselessEdge @ EFFECT_CEASELESS_EDGE
.4byte BattleScript_EffectShellTrap @ EFFECT_SHELL_TRAP .4byte BattleScript_EffectShellTrap @ EFFECT_SHELL_TRAP
.4byte BattleScript_EffectDireClaw @ EFFECT_DIRE_CLAW
BattleScript_EffectDireClaw::
setmoveeffect MOVE_EFFECT_DIRE_CLAW
goto BattleScript_EffectHit
BattleScript_EffectShellTrap: BattleScript_EffectShellTrap:
jumpifnodamage BattleScript_EffectShellTrap_Failed jumpifnodamage BattleScript_EffectShellTrap_Failed

View File

@ -371,8 +371,9 @@
#define MOVE_EFFECT_RELIC_SONG 69 #define MOVE_EFFECT_RELIC_SONG 69
#define MOVE_EFFECT_TRAP_BOTH 70 #define MOVE_EFFECT_TRAP_BOTH 70
#define MOVE_EFFECT_DOUBLE_SHOCK 71 #define MOVE_EFFECT_DOUBLE_SHOCK 71
#define MOVE_EFFECT_DIRE_CLAW 72
#define NUM_MOVE_EFFECTS 72 #define NUM_MOVE_EFFECTS 73
#define MOVE_EFFECT_AFFECTS_USER 0x4000 #define MOVE_EFFECT_AFFECTS_USER 0x4000
#define MOVE_EFFECT_CERTAIN 0x8000 #define MOVE_EFFECT_CERTAIN 0x8000

View File

@ -399,7 +399,8 @@
#define EFFECT_VICTORY_DANCE 393 #define EFFECT_VICTORY_DANCE 393
#define EFFECT_CEASELESS_EDGE 394 #define EFFECT_CEASELESS_EDGE 394
#define EFFECT_SHELL_TRAP 395 #define EFFECT_SHELL_TRAP 395
#define EFFECT_DIRE_CLAW 396
#define NUM_BATTLE_MOVE_EFFECTS 396 #define NUM_BATTLE_MOVE_EFFECTS 397
#endif // GUARD_CONSTANTS_BATTLE_MOVE_EFFECTS_H #endif // GUARD_CONSTANTS_BATTLE_MOVE_EFFECTS_H

View File

@ -3647,6 +3647,22 @@ void SetMoveEffect(bool32 primary, u32 certain)
BattleScriptPush(gBattlescriptCurrInstr + 1); BattleScriptPush(gBattlescriptCurrInstr + 1);
gBattlescriptCurrInstr = BattleScript_DoubleShockRemoveType; gBattlescriptCurrInstr = BattleScript_DoubleShockRemoveType;
break; break;
case MOVE_EFFECT_DIRE_CLAW:
if (gBattleMons[gEffectBattler].status1)
{
gBattlescriptCurrInstr++;
}
else
{
DIRE_CLAW_STATUS_PICK:
gBattleScripting.moveEffect = Random() % 6;
if (gBattleScripting.moveEffect == MOVE_EFFECT_NONE
|| gBattleScripting.moveEffect == MOVE_EFFECT_BURN
|| gBattleScripting.moveEffect == MOVE_EFFECT_FREEZE)
goto DIRE_CLAW_STATUS_PICK;
SetMoveEffect(FALSE, 0);
}
break;
} }
} }
} }

View File

@ -13279,11 +13279,11 @@ const struct BattleMove gBattleMoves[MOVES_COUNT_Z] =
#else #else
.power = 60, .power = 60,
#endif #endif
.effect = EFFECT_PLACEHOLDER, // EFFECT_DIRE_CLAW, .effect = EFFECT_DIRE_CLAW,
.type = TYPE_POISON, .type = TYPE_POISON,
.accuracy = 100, .accuracy = 100,
.pp = 15, .pp = 15,
.secondaryEffectChance = 0, .secondaryEffectChance = 50,
.target = MOVE_TARGET_SELECTED, .target = MOVE_TARGET_SELECTED,
.priority = 0, .priority = 0,
.flags = FLAG_MAKES_CONTACT | FLAG_PROTECT_AFFECTED | FLAG_MIRROR_MOVE_AFFECTED | FLAG_KINGS_ROCK_AFFECTED | FLAG_SHEER_FORCE_BOOST, .flags = FLAG_MAKES_CONTACT | FLAG_PROTECT_AFFECTED | FLAG_MIRROR_MOVE_AFFECTED | FLAG_KINGS_ROCK_AFFECTED | FLAG_SHEER_FORCE_BOOST,