mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2024-11-25 08:16:04 +00:00
more ME dialogue cleanup
This commit is contained in:
parent
24bbb0931c
commit
a1d1de2c0d
@ -17,6 +17,14 @@ import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/game-mode";
|
||||
/** the i18n namespace for this encounter */
|
||||
const namespace = "mysteryEncounter:offerYouCantRefuse";
|
||||
|
||||
/**
|
||||
* Money offered starts at base value of Relic Gold, increasing linearly up to 3x Relic Gold based on the starter tier of the Pokemon being purchased
|
||||
* Starter value 1-3 -> Relic Gold
|
||||
* Starter value 10 -> 3 * Relic Gold
|
||||
*/
|
||||
const MONEY_MINIMUM_MULTIPLIER = 10;
|
||||
const MONEY_MAXIMUM_MULTIPLIER = 30;
|
||||
|
||||
/**
|
||||
* An Offer You Can't Refuse encounter.
|
||||
* @see {@link https://github.com/pagefaultgames/pokerogue/issues/3808 | GitHub Issue #3808}
|
||||
@ -62,12 +70,9 @@ export const AnOfferYouCantRefuseEncounter: MysteryEncounter =
|
||||
const encounter = scene.currentBattle.mysteryEncounter!;
|
||||
const pokemon = getHighestStatTotalPlayerPokemon(scene, true, true);
|
||||
|
||||
// Base value of Relic Gold, increased linearly up to 3x Relic Gold based on the starter tier of the Pokemon being purchased
|
||||
// Starter value 1-3 -> 10x
|
||||
// Starter value 10 -> 30x
|
||||
const baseSpecies = pokemon.getSpeciesForm().getRootSpeciesId(true);
|
||||
const starterValue: number = speciesStarters[baseSpecies] ?? 1;
|
||||
const multiplier = Math.max(3 * starterValue, 10);
|
||||
const multiplier = Math.max(MONEY_MAXIMUM_MULTIPLIER / 10 * starterValue, MONEY_MINIMUM_MULTIPLIER);
|
||||
const price = scene.getWaveMoneyAmount(multiplier);
|
||||
|
||||
encounter.setDialogueToken("strongestPokemon", pokemon.getNameToRender());
|
||||
|
@ -63,7 +63,7 @@ export const DepartmentStoreSaleEncounter: MysteryEncounter =
|
||||
// Choose TMs
|
||||
const modifiers: ModifierTypeFunc[] = [];
|
||||
let i = 0;
|
||||
while (i < 6) {
|
||||
while (i < 5) {
|
||||
// 2/2/1 weight on TM rarity
|
||||
const roll = randSeedInt(5);
|
||||
if (roll < 2) {
|
||||
|
@ -27,6 +27,8 @@ const TRAINER_THROW_ANIMATION_TIMES = [512, 184, 768];
|
||||
|
||||
const SAFARI_MONEY_MULTIPLIER = 2;
|
||||
|
||||
const NUM_SAFARI_ENCOUNTERS = 3;
|
||||
|
||||
/**
|
||||
* Safari Zone encounter.
|
||||
* @see {@link https://github.com/pagefaultgames/pokerogue/issues/3800 | GitHub Issue #3800}
|
||||
@ -55,6 +57,10 @@ export const SafariZoneEncounter: MysteryEncounter =
|
||||
.withTitle(`${namespace}.title`)
|
||||
.withDescription(`${namespace}.description`)
|
||||
.withQuery(`${namespace}.query`)
|
||||
.withOnInit((scene: BattleScene) => {
|
||||
scene.currentBattle.mysteryEncounter?.setDialogueToken("numEncounters", NUM_SAFARI_ENCOUNTERS.toString());
|
||||
return true;
|
||||
})
|
||||
.withOption(MysteryEncounterOptionBuilder
|
||||
.newOptionWithMode(MysteryEncounterOptionMode.DISABLED_OR_DEFAULT)
|
||||
.withSceneRequirement(new MoneyRequirement(0, SAFARI_MONEY_MULTIPLIER)) // Cost equal to 1 Max Revive
|
||||
@ -72,7 +78,7 @@ export const SafariZoneEncounter: MysteryEncounter =
|
||||
const encounter = scene.currentBattle.mysteryEncounter!;
|
||||
encounter.continuousEncounter = true;
|
||||
encounter.misc = {
|
||||
safariPokemonRemaining: 3
|
||||
safariPokemonRemaining: NUM_SAFARI_ENCOUNTERS
|
||||
};
|
||||
updatePlayerMoney(scene, -(encounter.options[0].requirements[0] as MoneyRequirement).requiredMoney);
|
||||
// Load bait/mud assets
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"intro": "An {{oricorioName}} dances sadly alone, without a partner.",
|
||||
"title": "Dancing Lessons",
|
||||
"description": "The {{oricorioName}} doesn't seem aggressive, if anything it seems sad.\n\nMaybe it just wants someone to dance with...",
|
||||
"description": "The {{oricorioName}} doesn't seem aggressive, if anything it seems despondent.\n\nPerhaps it just wants someone to dance with...",
|
||||
"query": "What will you do?",
|
||||
"option": {
|
||||
"1": {
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"intro": "It's a safari zone!",
|
||||
"title": "The Safari Zone",
|
||||
"description": "There are all kinds of rare and special Pokémon that can be found here!\nIf you choose to enter, you'll have a time limit of 3 wild encounters where you can try to catch these special Pokémon.\n\nBeware, though. These Pokémon may flee before you're able to catch them!",
|
||||
"description": "There are all kinds of rare and special Pokémon that can be found here!\nIf you choose to enter, you'll have a time limit of @[TOOLTIP_TITLE]{{{numEncounters}} wild encounters} where you can try to catch these special Pokémon.\n\nBeware, though. These Pokémon may flee before you're able to catch them!",
|
||||
"query": "Would you like to enter?",
|
||||
"option": {
|
||||
"1": {
|
||||
|
@ -25,7 +25,7 @@
|
||||
"outro": "Look how happy your {{chosenPokemon}} is now!$Here, you can have these as well.",
|
||||
"outro_failed": "How disappointing...$It looks like you still have a long way\nto go to earn your Pokémon's trust!",
|
||||
"gained_eggs": "@s{item_fanfare}You received {{numEggs}}!",
|
||||
"eggs_tooltip": "\n(+) Earn {{eggs}}",
|
||||
"eggs_tooltip": "\n(+) Earn @[TOOLTIP_TITLE]{{{eggs}}}",
|
||||
"numEggs_one": "{{count}} {{rarity}} Egg",
|
||||
"numEggs_other": "{{count}} {{rarity}} Eggs"
|
||||
}
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"intro": "It's a massive {{shuckleName}} and what appears\nto be a large stash of... juice?",
|
||||
"title": "The Strong Stuff",
|
||||
"description": "The {{shuckleName}} that blocks your path looks incredibly strong. Meanwhile, the juice next to it is emanating power of some kind.\n\nThe {{shuckleName}} extends its feelers in your direction. It seems like it wants to do something...",
|
||||
"description": "The {{shuckleName}} that blocks your path looks formidable. Meanwhile, the juice next to it emanates power of some kind.\n\nThe {{shuckleName}} extends its feelers in your direction. It seems like it wants to do something...",
|
||||
"query": "What will you do?",
|
||||
"option": {
|
||||
"1": {
|
||||
|
@ -3,12 +3,12 @@
|
||||
"speaker": "The Winstrates",
|
||||
"intro_dialogue": "We're the Winstrates!$What do you say to taking on our family in a series of Pokémon battles?",
|
||||
"title": "The Winstrate Challenge",
|
||||
"description": "The Winstrates are a family of 5 trainers, and they want to battle! If you beat all of them back-to-back, they'll give you a grand prize. But can you handle the heat?",
|
||||
"description": "The Winstrates are a family of @[TOOLTIP_TITLE]{5 trainers}, and they want to battle! If you beat all of them back-to-back, they'll give you a grand prize. But can you handle the heat?",
|
||||
"query": "What will you do?",
|
||||
"option": {
|
||||
"1": {
|
||||
"label": "Accept the Challenge",
|
||||
"tooltip": "(-) Brutal Battle\n(+) Special Item Reward",
|
||||
"tooltip": "(-) Brutal Battle Against 5 Trainers\n(+) Special Item Reward",
|
||||
"selected": "Let the challenge begin!"
|
||||
},
|
||||
"2": {
|
||||
|
@ -98,7 +98,7 @@ describe("Department Store Sale - Mystery Encounter", () => {
|
||||
|
||||
expect(scene.ui.getMode()).to.equal(Mode.MODIFIER_SELECT);
|
||||
const modifierSelectHandler = scene.ui.handlers.find(h => h instanceof ModifierSelectUiHandler) as ModifierSelectUiHandler;
|
||||
expect(modifierSelectHandler.options.length).toEqual(4);
|
||||
expect(modifierSelectHandler.options.length).toEqual(5);
|
||||
for (const option of modifierSelectHandler.options) {
|
||||
expect(option.modifierTypeOption.type.id).toContain("TM_");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user