diff --git a/src/field/pokemon.ts b/src/field/pokemon.ts index da9cb5eac2c..47185c30d7d 100644 --- a/src/field/pokemon.ts +++ b/src/field/pokemon.ts @@ -3191,9 +3191,9 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container { fusionCry.destroy(); scene.time.delayedCall(Utils.fixedInt(Math.ceil(duration * 0.4)), () => { try { - SoundFade.fadeOut(cry, Utils.fixedInt(Math.ceil(duration * 0.2))); + SoundFade.fadeOut(gScene, cry, Utils.fixedInt(Math.ceil(duration * 0.2))); fusionCry = this.getFusionSpeciesForm().cry(Object.assign({ seek: Math.max(fusionCry.totalDuration * 0.4, 0) }, soundConfig)); - SoundFade.fadeIn(fusionCry, Utils.fixedInt(Math.ceil(duration * 0.2)), scene.masterVolume * scene.seVolume, 0); + SoundFade.fadeIn(gScene, fusionCry, Utils.fixedInt(Math.ceil(duration * 0.2)), scene.masterVolume * scene.seVolume, 0); } catch (err) { console.error(err); } @@ -3318,9 +3318,9 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container { frameProgress -= frameThreshold; } if (i === transitionIndex) { - SoundFade.fadeOut(cry, Utils.fixedInt(Math.ceil((duration / rate) * 0.2))); + SoundFade.fadeOut(gScene, cry, Utils.fixedInt(Math.ceil((duration / rate) * 0.2))); fusionCry = gScene.playSound(fusionCryKey, Object.assign({ seek: Math.max(fusionCry.totalDuration * 0.4, 0), rate: rate })); - SoundFade.fadeIn(fusionCry, Utils.fixedInt(Math.ceil((duration / rate) * 0.2)), gScene.masterVolume * gScene.seVolume, 0); + SoundFade.fadeIn(gScene, fusionCry, Utils.fixedInt(Math.ceil((duration / rate) * 0.2)), gScene.masterVolume * gScene.seVolume, 0); } rate *= 0.99; if (cry && !cry.pendingRemove) { diff --git a/src/phases/egg-hatch-phase.ts b/src/phases/egg-hatch-phase.ts index 1c1dfff60a1..f09f053d0c2 100644 --- a/src/phases/egg-hatch-phase.ts +++ b/src/phases/egg-hatch-phase.ts @@ -285,7 +285,7 @@ export class EggHatchPhase extends Phase { this.canSkip = false; this.hatched = true; if (this.evolutionBgm) { - SoundFade.fadeOut(this.evolutionBgm, Utils.fixedInt(100)); + SoundFade.fadeOut(gScene, this.evolutionBgm, Utils.fixedInt(100)); } for (let e = 0; e < 5; e++) { gScene.time.delayedCall(Utils.fixedInt(375 * e), () => gScene.playSound("se/egg_hatch", { volume: 1 - (e * 0.2) })); diff --git a/src/phases/evolution-phase.ts b/src/phases/evolution-phase.ts index f6df6ccc4ca..c6e9a8fc271 100644 --- a/src/phases/evolution-phase.ts +++ b/src/phases/evolution-phase.ts @@ -189,7 +189,7 @@ export class EvolutionPhase extends Phase { } }); - SoundFade.fadeOut(evolutionBgm, 100); + SoundFade.fadeOut(gScene, evolutionBgm, 100); gScene.unshiftPhase(new EndEvolutionPhase()); @@ -249,7 +249,7 @@ export class EvolutionPhase extends Phase { alpha: 0, duration: 250, onComplete: () => { - SoundFade.fadeOut(evolutionBgm, 100); + SoundFade.fadeOut(gScene, evolutionBgm, 100); gScene.time.delayedCall(250, () => { this.pokemon.cry(); gScene.time.delayedCall(1250, () => {