mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2024-11-30 10:46:05 +00:00
PR cleanup and commit suggestions
This commit is contained in:
parent
b82e8674cc
commit
39f91167c7
@ -181,14 +181,6 @@ function getTextWithDialogueTokens(scene: BattleScene, textKey: TemplateStringsA
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Apply dialogue tokens
|
|
||||||
// const dialogueTokens = scene.currentBattle?.mysteryEncounter?.dialogueTokens;
|
|
||||||
// if (dialogueTokens) {
|
|
||||||
// dialogueTokens.forEach((value) => {
|
|
||||||
// textString = textString.replace(value[0], value[1]);
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
|
|
||||||
return i18next.t(textKey, scene.currentBattle?.mysteryEncounter?.dialogueTokens);
|
return i18next.t(textKey, scene.currentBattle?.mysteryEncounter?.dialogueTokens);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -95,7 +95,7 @@ export default interface IMysteryEncounter {
|
|||||||
* Can be set for uses programatic dialogue during an encounter (storing the name of one of the party's pokemon, etc.)
|
* Can be set for uses programatic dialogue during an encounter (storing the name of one of the party's pokemon, etc.)
|
||||||
* Example use: see MYSTERIOUS_CHEST
|
* Example use: see MYSTERIOUS_CHEST
|
||||||
*/
|
*/
|
||||||
dialogueTokens?: { [key: string]: string; };
|
dialogueTokens?: Record<string, string>;
|
||||||
/**
|
/**
|
||||||
* Should be set depending upon option selected as part of an encounter
|
* Should be set depending upon option selected as part of an encounter
|
||||||
* For example, if there is no battle as part of the encounter/selected option, should be set to NO_BATTLE
|
* For example, if there is no battle as part of the encounter/selected option, should be set to NO_BATTLE
|
||||||
@ -350,7 +350,7 @@ export class MysteryEncounterBuilder implements Partial<IMysteryEncounter> {
|
|||||||
primaryPokemonRequirements?: EncounterPokemonRequirement[] = [];
|
primaryPokemonRequirements?: EncounterPokemonRequirement[] = [];
|
||||||
secondaryPokemonRequirements ?: EncounterPokemonRequirement[] = [];
|
secondaryPokemonRequirements ?: EncounterPokemonRequirement[] = [];
|
||||||
excludePrimaryFromSupportRequirements?: boolean;
|
excludePrimaryFromSupportRequirements?: boolean;
|
||||||
dialogueTokens?: { [key: string]: string; };
|
dialogueTokens?: Record<string, string>;
|
||||||
doEncounterExp?: (scene: BattleScene) => boolean;
|
doEncounterExp?: (scene: BattleScene) => boolean;
|
||||||
doEncounterRewards?: (scene: BattleScene) => boolean;
|
doEncounterRewards?: (scene: BattleScene) => boolean;
|
||||||
onInit?: (scene: BattleScene) => boolean;
|
onInit?: (scene: BattleScene) => boolean;
|
||||||
|
@ -6,6 +6,7 @@ import { SimpleTranslationEntries } from "#app/interfaces/locales";
|
|||||||
* '@d{<number>}' will add a time delay to text animation for Message and Dialogue strings
|
* '@d{<number>}' will add a time delay to text animation for Message and Dialogue strings
|
||||||
*
|
*
|
||||||
* '{{<token>}}' will auto-inject the matching token value for the specified Encounter that is stored in dialogueTokens
|
* '{{<token>}}' will auto-inject the matching token value for the specified Encounter that is stored in dialogueTokens
|
||||||
|
* (see [i18next interpolations](https://www.i18next.com/translation-function/interpolation))
|
||||||
*
|
*
|
||||||
* '@[<TextStyle>]{<text>}' will auto-color the given text to a specified TextStyle (e.g. TextStyle.SUMMARY_GREEN)
|
* '@[<TextStyle>]{<text>}' will auto-color the given text to a specified TextStyle (e.g. TextStyle.SUMMARY_GREEN)
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user