mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-27 18:52:19 +02:00
fixed automated tests
This commit is contained in:
parent
a8da0c6dea
commit
c37d90b1fa
@ -10397,8 +10397,7 @@ export function initMoves() {
|
|||||||
.ignoresVirtual(),
|
.ignoresVirtual(),
|
||||||
new AttackMove(Moves.SHELL_SIDE_ARM, Type.POISON, MoveCategory.SPECIAL, 90, 100, 10, 20, 0, 8)
|
new AttackMove(Moves.SHELL_SIDE_ARM, Type.POISON, MoveCategory.SPECIAL, 90, 100, 10, 20, 0, 8)
|
||||||
.attr(ShellSideArmCategoryAttr)
|
.attr(ShellSideArmCategoryAttr)
|
||||||
.attr(StatusEffectAttr, StatusEffect.POISON)
|
.attr(StatusEffectAttr, StatusEffect.POISON),
|
||||||
.makesContact(false),
|
|
||||||
new AttackMove(Moves.MISTY_EXPLOSION, Type.FAIRY, MoveCategory.SPECIAL, 100, 100, 5, -1, 0, 8)
|
new AttackMove(Moves.MISTY_EXPLOSION, Type.FAIRY, MoveCategory.SPECIAL, 100, 100, 5, -1, 0, 8)
|
||||||
.attr(SacrificialAttr)
|
.attr(SacrificialAttr)
|
||||||
.target(MoveTarget.ALL_NEAR_OTHERS)
|
.target(MoveTarget.ALL_NEAR_OTHERS)
|
||||||
|
@ -34,6 +34,22 @@ describe("Moves - Shell Side Arm", () => {
|
|||||||
.enemyMoveset(Moves.SPLASH);
|
.enemyMoveset(Moves.SPLASH);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("should not make contact if the move stays special", async () => {
|
||||||
|
game.override.enemySpecies(Species.SLOWBRO).enemyAbility(Abilities.ROUGH_SKIN);
|
||||||
|
|
||||||
|
await game.classicMode.startBattle([ Species.XURKITREE ]);
|
||||||
|
|
||||||
|
const player = game.scene.getPlayerPokemon()!;
|
||||||
|
|
||||||
|
vi.spyOn(shellSideArmAttr, "apply");
|
||||||
|
|
||||||
|
game.move.select(Moves.SHELL_SIDE_ARM);
|
||||||
|
await game.toNextTurn();
|
||||||
|
|
||||||
|
expect(shellSideArmAttr.apply).toHaveLastReturnedWith(false);
|
||||||
|
expect(player.getMaxHp()).toBe(player.hp);
|
||||||
|
});
|
||||||
|
|
||||||
it("becomes a physical attack if forecasted to deal more damage as physical", async () => {
|
it("becomes a physical attack if forecasted to deal more damage as physical", async () => {
|
||||||
game.override.enemySpecies(Species.SNORLAX);
|
game.override.enemySpecies(Species.SNORLAX);
|
||||||
|
|
||||||
@ -93,21 +109,4 @@ describe("Moves - Shell Side Arm", () => {
|
|||||||
|
|
||||||
expect(shellSideArmAttr.apply).toHaveLastReturnedWith(false);
|
expect(shellSideArmAttr.apply).toHaveLastReturnedWith(false);
|
||||||
});
|
});
|
||||||
|
|
||||||
/** The move should stay special (which it does) and make no contact but the MAKES_CONTACT flag is set */
|
|
||||||
it.skip("should not make contact if the move stays special", async () => {
|
|
||||||
game.override.enemySpecies(Species.SLOWBRO).enemyAbility(Abilities.ROUGH_SKIN);
|
|
||||||
|
|
||||||
await game.classicMode.startBattle([ Species.XURKITREE ]);
|
|
||||||
|
|
||||||
const player = game.scene.getPlayerPokemon()!;
|
|
||||||
|
|
||||||
vi.spyOn(shellSideArmAttr, "apply");
|
|
||||||
|
|
||||||
game.move.select(Moves.SHELL_SIDE_ARM);
|
|
||||||
await game.toNextTurn();
|
|
||||||
|
|
||||||
expect(shellSideArmAttr.apply).toHaveLastReturnedWith(false);
|
|
||||||
expect(player.getMaxHp()).toBe(player.hp);
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user