mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-11 10:52:17 +02:00
Made showText=> summary a promise
This commit is contained in:
parent
2eed9b137d
commit
e5fb9d63aa
@ -83,7 +83,8 @@ export class LearnMovePhase extends PlayerPartyMemberPokemonPhase {
|
|||||||
*/
|
*/
|
||||||
forgetMoveProcess(move: Move, pokemon: Pokemon) {
|
forgetMoveProcess(move: Move, pokemon: Pokemon) {
|
||||||
this.scene.ui.setMode(this.messageMode);
|
this.scene.ui.setMode(this.messageMode);
|
||||||
this.scene.ui.showText(i18next.t("battle:learnMoveForgetQuestion"), null, () => {
|
this.scene.ui.showTextPromise(i18next.t("battle:learnMoveForgetQuestion"), undefined, true)
|
||||||
|
.then(() => {
|
||||||
this.scene.ui.setModeWithoutClear(Mode.SUMMARY, pokemon, SummaryUiMode.LEARN_MOVE, move, (moveIndex: integer) => {
|
this.scene.ui.setModeWithoutClear(Mode.SUMMARY, pokemon, SummaryUiMode.LEARN_MOVE, move, (moveIndex: integer) => {
|
||||||
if (moveIndex === 4) {
|
if (moveIndex === 4) {
|
||||||
this.scene.ui.setMode(this.messageMode).then(() => this.rejectMoveAndEnd(move, pokemon));
|
this.scene.ui.setMode(this.messageMode).then(() => this.rejectMoveAndEnd(move, pokemon));
|
||||||
@ -93,7 +94,7 @@ export class LearnMovePhase extends PlayerPartyMemberPokemonPhase {
|
|||||||
const fullText = [i18next.t("battle:countdownPoof"), forgetSuccessText, i18next.t("battle:learnMoveAnd")].join("$");
|
const fullText = [i18next.t("battle:countdownPoof"), forgetSuccessText, i18next.t("battle:learnMoveAnd")].join("$");
|
||||||
this.scene.ui.setMode(this.messageMode).then(() => this.learnMove(moveIndex, move, pokemon, fullText));
|
this.scene.ui.setMode(this.messageMode).then(() => this.learnMove(moveIndex, move, pokemon, fullText));
|
||||||
});
|
});
|
||||||
}, null, true);
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user