Merge branch 'beta' into internal-pokedex

This commit is contained in:
damocleas 2025-02-07 19:44:27 -05:00 committed by GitHub
commit 9ab7654838
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 18 additions and 5 deletions

Binary file not shown.

View File

@ -2871,7 +2871,7 @@ export class SyrupBombTag extends BattlerTag {
/**
* Telekinesis raises the target into the air for three turns and causes all moves used against the target (aside from OHKO moves) to hit the target unless the target is in a semi-invulnerable state from Fly/Dig.
* The first effect is provided by {@linkcode FloatingTag}, the accuracy-bypass effect is provided by TelekinesisTag
* The effects of Telekinesis can be baton passed to a teammate. Unlike the mainline games, Telekinesis can be baton-passed to Mega Gengar.
* The effects of Telekinesis can be baton passed to a teammate.
* @see {@link https://bulbapedia.bulbagarden.net/wiki/Telekinesis_(move) | Moves.TELEKINESIS}
*/
export class TelekinesisTag extends BattlerTag {

View File

@ -10429,9 +10429,8 @@ export function initMoves() {
new AttackMove(Moves.PIKA_PAPOW, Type.ELECTRIC, MoveCategory.SPECIAL, -1, -1, 20, -1, 0, 7)
.attr(FriendshipPowerAttr),
new AttackMove(Moves.BOUNCY_BUBBLE, Type.WATER, MoveCategory.SPECIAL, 60, 100, 20, -1, 0, 7)
.attr(HitHealAttr) // Custom
.triageMove()
.target(MoveTarget.ALL_NEAR_ENEMIES),
.attr(HitHealAttr, 1)
.triageMove(),
new AttackMove(Moves.BUZZY_BUZZ, Type.ELECTRIC, MoveCategory.SPECIAL, 60, 100, 20, 100, 0, 7)
.attr(StatusEffectAttr, StatusEffect.PARALYSIS),
new AttackMove(Moves.SIZZLY_SLIDE, Type.FIRE, MoveCategory.PHYSICAL, 60, 100, 20, 100, 0, 7)

View File

@ -3234,7 +3234,7 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
}
for (const tag of source.summonData.tags) {
if (!tag.isBatonPassable) {
if (!tag.isBatonPassable || (tag.tagType === BattlerTagType.TELEKINESIS && this.species.speciesId === Species.GENGAR && this.getFormKey() === "mega")) {
continue;
}

View File

@ -7,6 +7,7 @@ import { MoveResult } from "#app/field/pokemon";
import GameManager from "#test/utils/gameManager";
import Phaser from "phaser";
import { afterEach, beforeAll, beforeEach, describe, it, expect, vi } from "vitest";
import { BattlerIndex } from "#app/battle";
describe("Moves - Telekinesis", () => {
let phaserGame: Phaser.Game;
@ -121,4 +122,17 @@ describe("Moves - Telekinesis", () => {
expect(enemyOpponent.getTag(BattlerTagType.FLOATING)).toBeUndefined();
expect(playerPokemon.getLastXMoves()[0].result).toBe(MoveResult.SUCCESS);
});
it("should not be baton passed onto a mega gengar", async () => {
game.override.moveset([ Moves.BATON_PASS ])
.enemyMoveset([ Moves.TELEKINESIS ])
.starterForms({ [Species.GENGAR]: 1 });
await game.classicMode.startBattle([ Species.MAGIKARP, Species.GENGAR ]);
game.move.select(Moves.BATON_PASS);
game.doSelectPartyPokemon(1);
await game.setTurnOrder([ BattlerIndex.ENEMY, BattlerIndex.PLAYER ]);
await game.phaseInterceptor.to("BerryPhase");
expect(game.scene.getPlayerPokemon()!.getTag(BattlerTagType.TELEKINESIS)).toBeUndefined();
});
});