Class AdvancedAITests

java.lang.Object
com.pixelmonmod.pixelmon.api.test.impl.ai.AdvancedAITests

public class AdvancedAITests extends Object
These tests verify that the AdvancedAI will behave more intelligently than the TacticalAI and that it will switch Pokémon when advantageous.
  • Constructor Details

    • AdvancedAITests

      public AdvancedAITests()
  • Method Details

    • testSwitchesPoisonTypesIntoToxicSpikes

      public static CompletableFuture<TestResult> testSwitchesPoisonTypesIntoToxicSpikes(BattleTestHelper helper)
      If the Advanced AI should switch Pokémon and there are Toxic Spikes on its side of the field it will switch using a Poison-type Pokémon if possible.

      In this test, a Stoutland that knows Tackle and Take Down is on a team with a Shroodle that knows Knock Off and a Nickit that knows Knock Off. That team faces a Duskull that knows Splash. The Stoutland starts with two layers of Toxic Spikes on its side of the field. The Advanced AI is made unable to Dynamax.

           Turn 1
           The Advanced AI makes a decision.
           The Duskull uses Splash.
           -
           After Turn 1
           We verify that the Advanced AI switched Stoutland out for the Shroodle.
       
    • testDoesNotSwitchIfEntryHazardsWouldKO

      public static CompletableFuture<TestResult> testDoesNotSwitchIfEntryHazardsWouldKO(BattleTestHelper helper)
      If the Advanced AI should switch Pokémon, the AI will not switch in a Pokémon that would faint to entry hazards.

      In this test, a Drillbur that knows Drill Run is on a team with a Toucannon at 20% HP that knows Drill Peck and another Toucannon at 100% HP that knows Drill Peck. That team faces a Swoobat that knows Sleep Talk. The Drillbur starts with Stealth Rock on its side of the field. The Advanced AI is made unable to Dynamax.

           Turn 1
           The Advanced AI makes a decision.
           The Swoobat uses Sleep Talk.
           -
           After Turn 1
           We verify that the Advanced AI switched Drillbur out for the full health Toucannon.
       
    • testWillSwitchIntoImmuneMove

      public static CompletableFuture<TestResult> testWillSwitchIntoImmuneMove(BattleTestHelper helper)
      If the Advanced AI predicts that its opponent will use a specific move, then it will more likely switch a Pokémon that is immune to that move in.

      In this test, an Aggron that knows Metal Claw is on a team with a Toucannon that knows Take Down and a Luxray that also knows Take Down. That team faces a Seismitoad that knows Bubble Beam, Round, Gastro Acid, and Drain Punch. The Advanced AI is made unable to Dynamax.

      The Advanced AI should predict that the Seismitoad will use the 4x-effective Drain Punch on the Aggron, and though the Luxray has a higher base Defense than a Toucannon, the AI should switch in the Toucannon because both the Luxray and Toucannon have the same base Attack and the Toucannon will be immune to the Drain Punch.

           Turn 1
           The Advanced AI makes a decision.
           The Seismitoad uses Drain Punch.
           -
           After Turn 1
           We verify that the Advanced AI switched Aggron out for the Toucannon.
       
    • testSwitchesOutOfPerishSong

      public static CompletableFuture<TestResult> testSwitchesOutOfPerishSong(BattleTestHelper helper)
      The Advanced AI will always switch a Pokémon affected by Perish Song, if it is the last turn before the Pokémon would faint.

      In this test, a Snom that knows Powder Snow and Struggle Bug faces a Meloetta that knows Perish Song. The Snom has a Lillipup that knows Tackle and Growl on its team. The Meloetta has a Volcanion that knows Sleep Talk on its team. The Advanced AI is made unable to Dynamax.

           Turn 1
           The Advanced AI makes a decision.
           The Duskull uses Splash.
           -
           After Turn 1
           We verify that the Advanced AI switched Snom out for the Lillipup.