Class MetronomeTests

java.lang.Object
com.pixelmonmod.pixelmon.api.test.impl.item.MetronomeTests

public class MetronomeTests extends Object
  • Constructor Details

    • MetronomeTests

      public MetronomeTests()
  • Method Details

    • testShouldIncreaseDamageForMovesUsedSuccessfullyAndConsecutively

      public static CompletableFuture<TestResult> testShouldIncreaseDamageForMovesUsedSuccessfullyAndConsecutively(BattleTestHelper helper)
      A Metronome that is held by a Pokémon boosts the power of a move each time the move is used consecutively and successfully.

      In this test, a Wynaut that is holding a Metronome and that knows the move Psystrike faces off against a Cleffa that knows Sleep Talk and has max HP EVs. - Turn 1 The Wynaut attacks the Cleffa with Psystrike. The Cleffa does nothing with Sleep Talk. Turn 2 The Wynaut attacks the Cleffa with Psystrike. Before damage is calculated the Wynaut's Metronome boost is increased to 20 due to using Psystrike during the previous turn, which increases Psystrike's power by 20%. The Cleffa does nothing with Sleep Talk. - We verify that the Wynaut's first Psystrike has a move power of 100. We verify that the Wynaut's Metronome boost is increased to 20 for the second Psystrike. We verify that the Wynaut's second Psystrike has a move power of 120 (100*1.2). We verify that the Wynaut does more damage with the second Psystrike than with the first Psystrike.

    • testShouldResetTheMultiplierUponSwitchingOut

      public static CompletableFuture<TestResult> testShouldResetTheMultiplierUponSwitchingOut(BattleTestHelper helper)
      The boost to a move's power that are received from a Metronome item are reset upon switching out.

      In this test, a Zygarde that is holding a Metronome and that knows the move Core Enforcer faces off against a Blissey that knows Sleep Talk. - Turn 1 The Zygarde attacks the Blissey with Core Enforcer. The Blissey uses Sleep Talk which does nothing. Turn 2 The Zygarde attacks the Blissey with Metronome-boosted Core Enforcer. The Blissey uses Sleep Talk which does nothing. Turn 3 The Zygarde is switched out for the Magikarp. The Blissey uses Sleep Talk which does nothing. Turn 4 The Magikarp is switched out for the Zygarde. The Blissey uses Sleep Talk which does nothing. Turn 5 The Zygarde attacks the Blissey with Core Enforcer. The Blissey uses Sleep Talk which does nothing. - We verify that the Zygarde's attack during the second turn is boosted by the Zygarde's Metronome. We verify that the Zygarde's Metronome boost is reset after it has switched out and back in. We verify that the Zygarde does not receive a boost from its Metronome for the third Core Enforcer due to its Metronome boost being reset. We verify that the Zygarde does the same amount of damage with the third Core Enforcer as the first Core Enforcer.

    • testShouldResetTheMultiplierUponUsingADifferentMove

      public static CompletableFuture<TestResult> testShouldResetTheMultiplierUponUsingADifferentMove(BattleTestHelper helper)
      The boost to a move's power that are received from a Metronome item are reset upon using a different move.

      In this test, a Snorlax that is holding a Metronome and that knows Ice Beam and Thunderbolt faces off against a Blissey that knows Sleep Talk. - Turn 1 The Blissey uses Sleep Talk which does nothing. The Snorlax attacks the Blissey with Ice Beam. Turn 2 The Blissey uses Sleep Talk which does nothing. The Snorlax attacks the Blissey with a Metronome-boosted Ice Beam. Turn 3 The Blissey uses Sleep Talk which does nothing. The Snorlax attacks the Blissey with a non-boosted Thunderbolt. Turn 4 The Blissey uses Sleep Talk which does nothing. The Snorlax attacks the Blissey with a non-boosted Ice Beam. - We verify that the Snorlax's Metronome has its boost increased during its second turn, for its second Ice Beam. We verify that the Snorlax's second Ice Beam deals more damage than its first Ice Beam. We verify that the Snorlax's Metronome boost is reset for choosing to use Thunderbolt instead of Ice Beam. We verify that the Snorlax's Thunderbolt attack did the same amount of damage as its first Ice Beam attack. We verify that the Snorlax's Metronome boost is reset for choosing to use Ice Beam after using Thunderbolt. We verify that the Snorlax's non-boosted Ice Beam attack did the same amount of damage as its non-boosted Thunderbolt attack.

    • testShouldResetTheMultiplierUponHittingProtect

      public static CompletableFuture<TestResult> testShouldResetTheMultiplierUponHittingProtect(BattleTestHelper helper)
      The boost to a move's power that are received from a Metronome item are reset upon hitting a Pokémon that used Protect.

      In this test, a Wynaut that is holding a Metronome and that knows the move Psystrike faces off against a Cleffa that knows Sleep Talk and Protect and has max HP EVs. - Turn 1 The Wynaut attacks the Cleffa with Psystrike. The Cleffa does nothing with Sleep Talk. Turn 2 The Cleffa uses Protect. The Wynaut attacks the Cleffa with Metronome-boosted Psystrike which hits the Protect. The boost from the Metronome is lost and the next Psystrike will not be boosted by the Metronome. Turn 3 The Wynaut attacks the Cleffa with non-boosted Psystrike. The Cleffa does nothing with Sleep Talk. - We verify that the Wynaut's attack during the second turn is boosted by Wynaut's Metronome, even if the attack hits Protect. We verify that the Wynaut does not receive a boost from its Metronome for the third Psystrike. We verify that the Wynaut does the same amount of damage with the third Psystrike as the first Psystrike.

    • testShouldIncreaseMetronomeBoostOnChargingTurns

      public static CompletableFuture<TestResult> testShouldIncreaseMetronomeBoostOnChargingTurns(BattleTestHelper helper)
      A Pokémon's Metronome item should boost a move after the first turn of an attack that has an invulnerable or charging turn such that the move deals increased damage during the second turn when the Pokémon deals damage.

      In this test, the first battle participant has a Duskull that knows Dig and a second Duskull that knows Dig but also holds a Metronome. The second battle participant has one Blissey that knows Sleep Talk. - Turn 1 The Duskull without a Metronome targets the Blissey with Dig. The Duskull is now in the charging/invulnerable phase. The Blissey uses Sleep Talk, accomplishing nothing. Turn 2 The Duskull ends its invulnerability and attacks, dealing damage with Dig. The Blissey uses Sleep Talk, healing itself. Turn 3 The first battle participant switches out its first Duskull for the second Duskull that holds a Metronome. The Blissey uses Sleep Talk. Turn 4 The Duskull with a Metronome targets the Blissey with Dig. The Duskull is now in the charging/invulnerable phase. The Blissey uses Sleep Talk. Turn 5 Metronome's boost is increased to 20 for this attack. The Duskull ends its invulnerability and attacks, dealing damage with a Metronome-boosted Dig. The Blissey uses Sleep Talk, healing itself. - We verify that the Duskull with a Metronome has the value of its Metronome boost increased to 20 during the second turn of Dig when it deals damage to the target. We verify that the Duskull holding a Metronome did more damage than the Duskull not holding a Metronome.

    • testShouldNotIncreaseMetronomeBoostForAChargingTurnThatWasSkipped

      public static CompletableFuture<TestResult> testShouldNotIncreaseMetronomeBoostForAChargingTurnThatWasSkipped(BattleTestHelper helper)
      A Pokémon's Metronome item should not boost the power of a move if that move requires a charging or invulnerable turn, but that turn was skipped.

      In this test, the first battle participant has two Slowbro that both know Solar Beam and hold a Metronome. The second battle participant has one Blissey that knows Sunny Day and a second Blissey that knows Soft-Boiled and has the Cloud Nine ability. This is a Single battle, not a Double battle. - Turn 1 The first Blissey uses Sunny Day. The first Slowbro uses Solar Beam. Due to the Harsh Sunlight weather condition, Solar Beam skips its charging phase and instantly deals damage. The Solar Beam does not receive a boost from the first Slowbro's Metronome. Turn 2 Both players switch their Pokémon. Turn 3 The second Blissey uses Soft-Boiled, which has no affect. The second Slowbro uses Solar Beam. The second Blissey's Cloud Nine negates the Harsh Sunlight so the second Slowbro must charge the Solar Beam. Turn 4 The second Blissey uses Soft-Boiled, which has no affect. The second Slowbro deals damage with a Metronome-boosted Solar Beam, which is boosted due to using Solar Beam the previous turn. - We verify that the second Slowbro has the value of its Metronome boost increased to 20 for the second damage-dealing turn of its Solar Beam attack. We verify that the second Slowbro deals more damage than the first Slowbro.

    • testShouldUseTheCalledMoveToDetermineWhetherMetronomeBoostIncreases

      public static CompletableFuture<TestResult> testShouldUseTheCalledMoveToDetermineWhetherMetronomeBoostIncreases(BattleTestHelper helper)
      If a Pokémon uses a move that calls another move, the move that it turns into is what's taken into account when determining whether the bonus should accumulate or reset.

      In this test, a Goomy that is holding a Metronome and that knows Copycat and Surf faces off against a Clefable with max HP EVs that knows Soft-Boiled and Surf. The Clefable is faster than the Goomy. - Turn 1 The Clefable uses Surf. The Goomy uses Copycat, which copies the Clefable's Surf. Turn 2 The Clefable uses Surf. The Goomy uses Copycat, which copies the Clefable's Surf, which then raises the Goomy's Metronome boost to 20 because Goomy used Surf during the previous turn, which makes the Surf deal increased damage. Turn 3 The Clefable uses Soft-Boiled. The Goomy uses Surf and, again, before damage is calculated, Goomy's Metronome boost has its value raised from 20 to 40, further increasing the power and damage that Surf does. - We verify that the Goomy's has its Metronome boost value increased to 20 for the second turn when it copies Surf. We verify that the Goomy deals more damage with the second Surf than the first Surf. We verify that the Goomy's has its Metronome boost value increased from 20 to 40 for the third turn when it uses Surf as its original move. We verify that the Goomy deals more damage with the third Surf than the second Surf.

    • testShouldNotIncreaseBoostForEachHitOfMultiHitMove

      public static CompletableFuture<TestResult> testShouldNotIncreaseBoostForEachHitOfMultiHitMove(BattleTestHelper helper)
      Moves that hit multiple times in one turn will only increase a Metronome's boost once per turn.

      In this test, a Cubone that is given the Skill Link ability, that is holding a Metronome, and that knows the move Bone Rush faces off against a Blastoise that knows Sleep Talk. Skill Link is used so that Bone Rush always hits 5 times. - Turn 1 The Cubone attacks the Blastoise with Bone Rush. The Blastoise does nothing with Sleep Talk. Turn 2 The Cubone attacks the Blastoise with Bone Rush. Before damage is calculated the Cubone's Metronome boost is increased to 20 due to using Bone Rush during the previous turn, which increases Bone Rush's power by 20%. The Blastoise does nothing with Sleep Talk. - We verify that the Cubone's Metronome boost is still at 0 after the first Bone Rush. We verify that the last hit of Cubone's first Bone Rush has a move power of 25. We verify that the Cubone's Metronome boost has only increased to 20 after the second Bone Rush is finished. We verify that the last hit of Cubone's second Bone Rush has a move power of 30 (25*1.2). We verify that the Cubone does more damage with the second Bone Rush than with the first Bone Rush.

    • testShouldNotIncreaseBoostForEachHitOfMultiHitMoveWithMultipleAccuracyChecks

      public static CompletableFuture<TestResult> testShouldNotIncreaseBoostForEachHitOfMultiHitMoveWithMultipleAccuracyChecks(BattleTestHelper helper)
      Moves that hit multiple times in one turn will only increase a Metronome's boost once per turn (even if a multiple hit move has to make an accuracy check each turn).

      In this test, a Tandemaus that is holding a Metronome and that knows the move Population Bomb faces off against a Bisharp that knows Sleep Talk. - Turn 1 The Tandemaus attacks the Bisharp with Population Bomb. The Bisharp does nothing with Sleep Talk. Turn 2 The Tandemaus attacks the Bisharp with Population Bomb. Before damage is calculated the Tandemaus's Metronome boost is increased to 20 due to using Population Bomb during the previous turn, which increases Population Bomb's power by 20%. The Tandemaus does nothing with Sleep Talk. - We verify that the Tandemaus's Metronome boost is still at 0 after the first Population Bomb. We verify that the last hit of Tandemaus's first Population Bomb has a move power of 20. We verify that the Tandemaus's Metronome boost has only increased to 20 after the second Population Bomb is finished. We verify that the last hit of Tandemaus's second Population Bomb has a move power of 24 (20*1.2). We verify that the Tandemaus does more damage with the second Population Bomb than with the first Population Bomb.

    • testShouldNotIncreaseBoostForEachHitOfMultiHitMoveThatVariesInPower

      public static CompletableFuture<TestResult> testShouldNotIncreaseBoostForEachHitOfMultiHitMoveThatVariesInPower(BattleTestHelper helper)
      Moves that hit multiple times in one turn will only increase a Metronome's boost once per turn (even if a multiple hit move increases in power for each hit).

      In this test, a Hitmontop with the Intimidate ability, that is holding a Metronome, and that knows the move Triple Kick faces off against a Blastoise that knows Sleep Talk. Intimidate is used so that Hitmontop doesn't get extra power from its other default ability, Technician. - Turn 1 The Hitmontop attacks the Blastoise with Triple Kick. The Blastoise does nothing with Sleep Talk. Turn 2 The Hitmontop attacks the Blastoise with Triple Kick. Before damage is calculated the Hitmontop's Metronome boost is increased to 20 due to using Triple Kick during the previous turn, which increases Triple Kick's power by 20%. The Blastoise does nothing with Sleep Talk. - We verify that the Hitmontop's Metronome boost is still at 0 after the first Triple Kick. We verify that the last hit of Hitmontop's first Triple Kick has a move power of 30. We verify that the Hitmontop's Metronome boost has only increased to 20 after the second Triple Kick is finished. We verify that the last hit of Hitmontop's second Triple Kick has a move power of 36 (30*1.2). We verify that the Hitmontop does more damage with the second Triple Kick than with the first Triple Kick.