From 8fa75f68749f502373a996c42dcfb24219f5d99c Mon Sep 17 00:00:00 2001 From: AJ Fontaine Date: Mon, 4 Nov 2024 23:39:19 -0500 Subject: [PATCH] Integer to number in bounceanim signature --- src/data/pokeball.ts | 2 +- src/phases/attempt-capture-phase.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/data/pokeball.ts b/src/data/pokeball.ts index 1198ced580b..720d8af4421 100644 --- a/src/data/pokeball.ts +++ b/src/data/pokeball.ts @@ -106,7 +106,7 @@ export function getCriticalCaptureChance(scene: BattleScene, modifiedCatchRate: return Math.floor(catchingCharmMultiplier.value * dexMultiplier * Math.min(255, modifiedCatchRate) / 6); } -export function doPokeballBounceAnim(scene: BattleScene, pokeball: Phaser.GameObjects.Sprite, y1: number, y2: number, baseBounceDuration: integer, callback: Function, isCritical: boolean = false) { +export function doPokeballBounceAnim(scene: BattleScene, pokeball: Phaser.GameObjects.Sprite, y1: number, y2: number, baseBounceDuration: number, callback: Function, isCritical: boolean = false) { let bouncePower = 1; let bounceYOffset = y1; let bounceY = y2; diff --git a/src/phases/attempt-capture-phase.ts b/src/phases/attempt-capture-phase.ts index 1788e3c6e84..de10d1eca45 100644 --- a/src/phases/attempt-capture-phase.ts +++ b/src/phases/attempt-capture-phase.ts @@ -98,13 +98,13 @@ export class AttemptCapturePhase extends PokemonPhase { this.scene.time.delayedCall(17, () => this.pokeball.setTexture("pb", `${pokeballAtlasKey}`)); const doShake = () => { - // After the overall catch rate check, the game does 4 shake checks before confirming the catch. + // After the overall catch rate check, the game does 3 shake checks before confirming the catch. let shakeCount = 0; const pbX = this.pokeball.x; const shakeCounter = this.scene.tweens.addCounter({ from: 0, to: 1, - repeat: isCritical ? 2 : 4, // Critical captures only perform 2 shake checks + repeat: isCritical ? 2 : 4, // Critical captures only perform 1 shake check yoyo: true, ease: "Cubic.easeOut", duration: 250,