diff --git a/public/images/pokemon/variant/_masterlist.json b/public/images/pokemon/variant/_masterlist.json index f3e690395e1..e2feeaa9e55 100644 --- a/public/images/pokemon/variant/_masterlist.json +++ b/public/images/pokemon/variant/_masterlist.json @@ -3300,6 +3300,11 @@ 1, 1 ], + "307": [ + 0, + 1, + 1 + ], "308": [ 0, 1, @@ -6678,6 +6683,11 @@ 1, 1 ], + "307": [ + 0, + 1, + 1 + ], "308": [ 0, 1, diff --git a/public/images/pokemon/variant/back/307.json b/public/images/pokemon/variant/back/307.json index 3c2ef92171c..3bdadaa8e16 100644 --- a/public/images/pokemon/variant/back/307.json +++ b/public/images/pokemon/variant/back/307.json @@ -1,15 +1,5 @@ { "1": { - "7b6b6b": "314b76", - "b5adad": "677d98", - "e6dede": "c2cfdb", - "000000": "000000", - "3a84b5": "51876e", - "3a4a5a": "113926", - "6bcee6": "7edfb7", - "5aa5ce": "66c3a3" - }, - "2": { "7b6b6b": "7a5f5f", "b5adad": "9f8383", "e6dede": "deccc3", @@ -18,5 +8,15 @@ "3a4a5a": "5a2859", "6bcee6": "f4a8c8", "5aa5ce": "ce7bb0" + }, + "2": { + "7b6b6b": "314b76", + "b5adad": "677d98", + "e6dede": "c2cfdb", + "000000": "000000", + "3a84b5": "51876e", + "3a4a5a": "113926", + "6bcee6": "7edfb7", + "5aa5ce": "66c3a3" } } \ No newline at end of file diff --git a/public/images/pokemon/variant/back/female/307.json b/public/images/pokemon/variant/back/female/307.json new file mode 100644 index 00000000000..3bdadaa8e16 --- /dev/null +++ b/public/images/pokemon/variant/back/female/307.json @@ -0,0 +1,22 @@ +{ + "1": { + "7b6b6b": "7a5f5f", + "b5adad": "9f8383", + "e6dede": "deccc3", + "000000": "000000", + "3a84b5": "7e4377", + "3a4a5a": "5a2859", + "6bcee6": "f4a8c8", + "5aa5ce": "ce7bb0" + }, + "2": { + "7b6b6b": "314b76", + "b5adad": "677d98", + "e6dede": "c2cfdb", + "000000": "000000", + "3a84b5": "51876e", + "3a4a5a": "113926", + "6bcee6": "7edfb7", + "5aa5ce": "66c3a3" + } +} \ No newline at end of file diff --git a/public/images/pokemon/variant/female/307.json b/public/images/pokemon/variant/female/307.json new file mode 100644 index 00000000000..d3e6a2437f1 --- /dev/null +++ b/public/images/pokemon/variant/female/307.json @@ -0,0 +1,34 @@ +{ + "1": { + "7b6b6b": "7a5f5f", + "000000": "000000", + "e6dede": "deccc3", + "b5adad": "9f8383", + "4a4242": "4a4242", + "ffffff": "ffffff", + "3a4a5a": "5a2859", + "b5d6ff": "f4a8c8", + "6bcee6": "ce7bb0", + "d65252": "d65287", + "84424a": "84424a", + "3a84b5": "7e4377", + "5aa5ce": "b95ba1", + "d65273": "d65273" + }, + "2": { + "7b6b6b": "314b76", + "000000": "000000", + "e6dede": "c2cfdb", + "b5adad": "6f89aa", + "4a4242": "1e2f52", + "ffffff": "ffffff", + "3a4a5a": "113926", + "b5d6ff": "7edfb7", + "6bcee6": "66c3a3", + "d65252": "c067c7", + "84424a": "84424a", + "3a84b5": "375a47", + "5aa5ce": "579578", + "d65273": "d65273" + } +} \ No newline at end of file diff --git a/src/test/moves/ceaseless_edge.test.ts b/src/test/moves/ceaseless_edge.test.ts index de47027ccd5..6443e34d8d2 100644 --- a/src/test/moves/ceaseless_edge.test.ts +++ b/src/test/moves/ceaseless_edge.test.ts @@ -9,9 +9,10 @@ import { import {getMovePosition} from "#app/test/utils/gameManagerUtils"; import { Moves } from "#enums/moves"; import { Species } from "#enums/species"; -import { ArenaTagType } from "#app/enums/arena-tag-type.js"; -import { allMoves } from "#app/data/move.js"; -import { ArenaTagSide, ArenaTrapTag } from "#app/data/arena-tag.js"; +import { ArenaTagType } from "#app/enums/arena-tag-type"; +import { allMoves } from "#app/data/move"; +import { ArenaTagSide, ArenaTrapTag } from "#app/data/arena-tag"; +import { Abilities } from "#app/enums/abilities"; const TIMEOUT = 20 * 1000; @@ -33,6 +34,8 @@ describe("Moves - Ceaseless Edge", () => { game = new GameManager(phaserGame); vi.spyOn(overrides, "SINGLE_BATTLE_OVERRIDE", "get").mockReturnValue(true); vi.spyOn(overrides, "OPP_SPECIES_OVERRIDE", "get").mockReturnValue(Species.RATTATA); + vi.spyOn(overrides, "OPP_ABILITY_OVERRIDE", "get").mockReturnValue(Abilities.RUN_AWAY); + vi.spyOn(overrides, "OPP_PASSIVE_ABILITY_OVERRIDE", "get").mockReturnValue(Abilities.RUN_AWAY); vi.spyOn(overrides, "STARTING_LEVEL_OVERRIDE", "get").mockReturnValue(100); vi.spyOn(overrides, "OPP_LEVEL_OVERRIDE", "get").mockReturnValue(100); vi.spyOn(overrides, "MOVESET_OVERRIDE", "get").mockReturnValue([ Moves.CEASELESS_EDGE, Moves.SPLASH, Moves.ROAR ]); @@ -103,9 +106,8 @@ describe("Moves - Ceaseless Edge", () => { async () => { vi.spyOn(overrides, "STARTING_HELD_ITEMS_OVERRIDE", "get").mockReturnValue([{name: "MULTI_LENS"}]); vi.spyOn(overrides, "STARTING_WAVE_OVERRIDE", "get").mockReturnValue(5); - vi.spyOn(overrides, "OPP_SPECIES_OVERRIDE", "get").mockReturnValue(0); - await game.startBattle([ Species.SNORLAX, Species.MUNCHLAX ]); + await game.startBattle([ Species.ILLUMISE ]); const leadPokemon = game.scene.getPlayerPokemon(); expect(leadPokemon).toBeDefined(); diff --git a/src/ui/starter-select-ui-handler.ts b/src/ui/starter-select-ui-handler.ts index 25d1060f23e..0caf9ef6fa6 100644 --- a/src/ui/starter-select-ui-handler.ts +++ b/src/ui/starter-select-ui-handler.ts @@ -2322,10 +2322,13 @@ export default class StarterSelectUiHandler extends MessageUiHandler { const isValidForChallenge = new Utils.BooleanHolder(true); + const currentPartyValue = this.starterGens.reduce((total: number, gen: number, i: number) => total += this.scene.gameData.getSpeciesStarterValue(this.genSpecies[gen][this.starterCursors[i]].speciesId), 0); + const cursorCost = this.scene.gameData.getSpeciesStarterValue(species.speciesId); + const isValidNextPartyValue = (currentPartyValue + cursorCost) <= this.getValueLimit(); Challenge.applyChallenges(this.scene.gameMode, Challenge.ChallengeType.STARTER_CHOICE, species, isValidForChallenge, this.scene.gameData.getSpeciesDexAttrProps(species, this.dexAttrCursor), this.starterGens.length); const starterSprite = this.starterSelectGenIconContainers[this.getGenCursorWithScroll()].getAt(this.cursor) as Phaser.GameObjects.Sprite; starterSprite.setTexture(species.getIconAtlasKey(formIndex, shiny, variant), species.getIconId(female, formIndex, shiny, variant)); - starterSprite.setAlpha(isValidForChallenge.value ? 1 : 0.375); + starterSprite.setAlpha(isValidForChallenge.value && isValidNextPartyValue ? 1 : 0.375); this.checkIconId((this.starterSelectGenIconContainers[this.getGenCursorWithScroll()].getAt(this.cursor) as Phaser.GameObjects.Sprite), species, female, formIndex, shiny, variant); this.canCycleShiny = !!(dexEntry.caughtAttr & DexAttr.NON_SHINY && dexEntry.caughtAttr & DexAttr.SHINY); this.canCycleGender = !!(dexEntry.caughtAttr & DexAttr.MALE && dexEntry.caughtAttr & DexAttr.FEMALE);