Skip to content

Commit

Permalink
Make tera effect start after animation
Browse files Browse the repository at this point in the history
  • Loading branch information
Xavion3 committed Feb 11, 2025
1 parent adcab4b commit 50c7588
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/phases/tera-phase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ import { globalScene } from "#app/global-scene";
import { Type } from "#app/enums/type";
import { achvs } from "#app/system/achv";
import { SpeciesFormChangeTeraTrigger } from "#app/data/pokemon-forms";
import { CommonAnim } from "#app/data/battle-anims";
import { CommonAnimPhase } from "./common-anim-phase";
import { CommonAnim, CommonBattleAnim } from "#app/data/battle-anims";

export class TeraPhase extends BattlePhase {
public pokemon: Pokemon;
Expand All @@ -24,9 +23,9 @@ export class TeraPhase extends BattlePhase {
console.log(this.pokemon.name, "terastallized to", Type[this.pokemon.teraType].toString());

globalScene.queueMessage(i18next.t("battle:pokemonTerastallized", { pokemonNameWithAffix: getPokemonNameWithAffix(this.pokemon), type: i18next.t(`pokemonInfo:Type.${Type[this.pokemon.teraType]}`) }));
globalScene.unshiftPhase(new CommonAnimPhase(this.pokemon.getBattlerIndex(), undefined, CommonAnim.TERASTALLIZE));

this.end();
new CommonBattleAnim(CommonAnim.TERASTALLIZE, this.pokemon).play(false, () => {
this.end();
});
}


Expand Down

0 comments on commit 50c7588

Please sign in to comment.