Removed most uses of allRewards from across the code

This commit is contained in:
Wlowscha 2025-08-08 01:50:56 +02:00
parent f5d08567c9
commit 3f3bbf7d85
No known key found for this signature in database
GPG Key ID: 3C8F1AD330565D04
19 changed files with 63 additions and 92 deletions

View File

@ -49,4 +49,5 @@ export type SilentReward =
| TrainerItemId
| typeof RewardId.VOUCHER
| typeof RewardId.VOUCHER_PLUS
| typeof RewardId.VOUCHER_PREMIUM;
| typeof RewardId.VOUCHER_PREMIUM
| typeof RewardId.ROGUE_BALL;

View File

@ -150,7 +150,7 @@ export const ATrainersTestEncounter: MysteryEncounter = MysteryEncounterBuilder.
},
async () => {
const encounter = globalScene.currentBattle.mysteryEncounter!;
// Battle the stat trainer for an Egg and great allRewards
// Battle the stat trainer for an Egg and great rewards
const config: EnemyPartyConfig = encounter.enemyPartyConfigs[0];
await transitionMysteryEncounterIntroVisuals();

View File

@ -1,7 +1,7 @@
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
import { globalScene } from "#app/global-scene";
import { speciesStarterCosts } from "#balance/starters";
import { allRewards, allTrainerItems } from "#data/data-lists";
import { allTrainerItems } from "#data/data-lists";
import { MysteryEncounterOptionMode } from "#enums/mystery-encounter-option-mode";
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
import { MysteryEncounterType } from "#enums/mystery-encounter-type";
@ -136,7 +136,7 @@ export const AnOfferYouCantRefuseEncounter: MysteryEncounter = MysteryEncounterB
})
.withOptionPhase(async () => {
// Give the player a Shiny Charm
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards.SHINY_CHARM);
globalScene.phaseManager.unshiftNew("RewardPhase", TrainerItemId.SHINY_CHARM);
leaveEncounterWithoutBattle(true);
})
.build(),

View File

@ -1,11 +1,11 @@
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
import { globalScene } from "#app/global-scene";
import { allRewards } from "#data/data-lists";
import { Challenges } from "#enums/challenges";
import { MysteryEncounterOptionMode } from "#enums/mystery-encounter-option-mode";
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
import { MysteryEncounterType } from "#enums/mystery-encounter-type";
import type { PokemonType } from "#enums/pokemon-type";
import { RewardId } from "#enums/reward-id";
import { SpeciesId } from "#enums/species-id";
import type { HeldItemConfiguration } from "#items/held-item-data-types";
import type { EnemyPartyConfig, EnemyPokemonConfig } from "#mystery-encounters/encounter-phase-utils";
@ -160,7 +160,7 @@ export const DarkDealEncounter: MysteryEncounter = MysteryEncounterBuilder.withE
.withOptionPhase(async () => {
// Give the player 5 Rogue Balls
const encounter = globalScene.currentBattle.mysteryEncounter!;
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards.ROGUE_BALL);
globalScene.phaseManager.unshiftNew("RewardPhase", RewardId.ROGUE_BALL);
// Start encounter with random legendary (7-10 starter strength) that has level additive
// If this is a mono-type challenge, always ensure the required type is filtered for

View File

@ -1,11 +1,12 @@
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
import { timedEventManager } from "#app/global-event-manager";
import { globalScene } from "#app/global-scene";
import { allHeldItems, allRewards } from "#data/data-lists";
import { allHeldItems } from "#data/data-lists";
import { HeldItemCategoryId, HeldItemId, isItemInCategory } from "#enums/held-item-id";
import { MysteryEncounterOptionMode } from "#enums/mystery-encounter-option-mode";
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
import { MysteryEncounterType } from "#enums/mystery-encounter-type";
import { RewardId } from "#enums/reward-id";
import { SpeciesId } from "#enums/species-id";
import { TrainerItemId } from "#enums/trainer-item-id";
import type { PlayerPokemon, Pokemon } from "#field/pokemon";
@ -61,10 +62,10 @@ const doEventReward = () => {
return !fullStack;
});
if (candidates.length > 0) {
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards[randSeedItem(candidates)]);
globalScene.phaseManager.unshiftNew("RewardPhase", randSeedItem(candidates));
} else {
// At max stacks, give a Voucher instead
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards.VOUCHER);
globalScene.phaseManager.unshiftNew("RewardPhase", RewardId.VOUCHER);
}
}
};
@ -168,7 +169,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with
// At max stacks, give the first party pokemon a Shell Bell instead
backupOption();
} else {
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards.AMULET_COIN);
globalScene.phaseManager.unshiftNew("RewardPhase", TrainerItemId.AMULET_COIN);
doEventReward();
}
@ -238,7 +239,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with
// At max stacks, give the first party pokemon a Shell Bell instead
backupOption();
} else {
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards.CANDY_JAR);
globalScene.phaseManager.unshiftNew("RewardPhase", TrainerItemId.CANDY_JAR);
doEventReward();
}
} else {
@ -249,7 +250,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with
// At max stacks, give the first party pokemon a Shell Bell instead
backupOption();
} else {
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards.BERRY_POUCH);
globalScene.phaseManager.unshiftNew("RewardPhase", TrainerItemId.BERRY_POUCH);
doEventReward();
}
}
@ -321,7 +322,7 @@ export const DelibirdyEncounter: MysteryEncounter = MysteryEncounterBuilder.with
// At max stacks, give the first party pokemon a Shell Bell instead
backupOption();
} else {
globalScene.phaseManager.unshiftNew("RewardPhase", allRewards.HEALING_CHARM);
globalScene.phaseManager.unshiftNew("RewardPhase", TrainerItemId.HEALING_CHARM);
doEventReward();
}

View File

@ -4,8 +4,11 @@ import { MoveCategory } from "#enums/move-category";
import { MysteryEncounterOptionMode } from "#enums/mystery-encounter-option-mode";
import { MysteryEncounterTier } from "#enums/mystery-encounter-tier";
import { MysteryEncounterType } from "#enums/mystery-encounter-type";
import { RewardId } from "#enums/reward-id";
import { Stat } from "#enums/stat";
import { TrainerItemId } from "#enums/trainer-item-id";
import type { PlayerPokemon } from "#field/pokemon";
import { generateRewardOptionFromId } from "#items/reward-utils";
import type { PokemonMove } from "#moves/pokemon-move";
import {
leaveEncounterWithoutBattle,
@ -93,16 +96,16 @@ export const FieldTripEncounter: MysteryEncounter = MysteryEncounterBuilder.with
.withOptionPhase(async () => {
const encounter = globalScene.currentBattle.mysteryEncounter!;
if (encounter.misc.correctMove) {
const modifiers = [
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.ATK])!,
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.DEF])!,
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.SPD])!,
const rewards = [
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.ATK })!,
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.DEF })!,
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.SPD })!,
generateRewardOptionFromId(RewardId.DIRE_HIT)!,
generateRewardOptionFromId(RewardId.RARER_CANDY)!,
];
setEncounterRewards({
guaranteedRewardOptions: modifiers,
guaranteedRewardOptions: rewards,
fillRemaining: false,
});
}
@ -141,16 +144,16 @@ export const FieldTripEncounter: MysteryEncounter = MysteryEncounterBuilder.with
.withOptionPhase(async () => {
const encounter = globalScene.currentBattle.mysteryEncounter!;
if (encounter.misc.correctMove) {
const modifiers = [
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.SPATK])!,
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.SPDEF])!,
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.SPD])!,
const rewards = [
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.SPATK })!,
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.SPDEF })!,
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.SPD })!,
generateRewardOptionFromId(RewardId.DIRE_HIT)!,
generateRewardOptionFromId(RewardId.RARER_CANDY)!,
];
setEncounterRewards({
guaranteedRewardOptions: modifiers,
guaranteedRewardOptions: rewards,
fillRemaining: false,
});
}
@ -189,16 +192,16 @@ export const FieldTripEncounter: MysteryEncounter = MysteryEncounterBuilder.with
.withOptionPhase(async () => {
const encounter = globalScene.currentBattle.mysteryEncounter!;
if (encounter.misc.correctMove) {
const modifiers = [
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.ACC])!,
generateRewardOptionFromId(RewardId.TEMP_STAT_STAGE_BOOSTER, [Stat.SPD])!,
const rewards = [
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.ACC })!,
generateRewardOptionFromId({ id: RewardId.TEMP_STAT_STAGE_BOOSTER, args: Stat.SPD })!,
generateRewardOptionFromId(RewardId.GREAT_BALL)!,
generateRewardOptionFromId(RewardId.IV_SCANNER)!,
generateRewardOptionFromId(TrainerItemId.IV_SCANNER)!,
generateRewardOptionFromId(RewardId.RARER_CANDY)!,
];
setEncounterRewards({
guaranteedRewardOptions: modifiers,
guaranteedRewardOptions: rewards,
fillRemaining: false,
});
}

View File

@ -250,7 +250,6 @@ export const FieryFalloutEncounter: MysteryEncounter = MysteryEncounterBuilder.w
}
}
// No allRewards
leaveEncounterWithoutBattle(true);
},
)

View File

@ -99,7 +99,7 @@ export const FightOrFlightEncounter: MysteryEncounter = MysteryEncounterBuilder.
: RarityTier.GREAT;
generateRewardPoolWeights(getRewardPoolForType(RewardPoolType.PLAYER), globalScene.getPlayerParty(), 0);
let item: RewardOption | null = null;
// TMs and Candy Jar excluded from possible allRewards as they're too swingy in value for a singular item reward
// TMs and Candy Jar excluded from possible rewards as they're too swingy in value for a singular item reward
while (!item || isTmReward(item.type) || (item.type as TrainerItemReward).itemId === TrainerItemId.CANDY_JAR) {
item = generatePlayerRewardOptions(1, globalScene.getPlayerParty(), [], {
guaranteedRarityTiers: [tier],

View File

@ -426,7 +426,7 @@ export const GlobalTradeSystemEncounter: MysteryEncounter = MysteryEncounterBuil
generateRewardPoolWeights(getRewardPoolForType(RewardPoolType.PLAYER), party, 0);
let item: RewardOption | null = null;
// TMs excluded from possible allRewards
// TMs excluded from possible rewards
while (!item || isTmReward(item.type)) {
item = generatePlayerRewardOptions(1, party, [], {
guaranteedRarityTiers: [tier],

View File

@ -304,7 +304,7 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount
// Remove all Pokemon from the party except the chosen Pokemon
removePokemonFromPartyAndStoreHeldItems(encounter, pokemon1);
// Configure outro dialogue for egg allRewards
// Configure outro dialogue for egg rewards
encounter.dialogue.outro = [
{
speaker: trainerNameKey,
@ -363,7 +363,7 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount
// Remove all Pokemon from the party except the chosen Pokemon
removePokemonFromPartyAndStoreHeldItems(encounter, pokemon2);
// Configure outro dialogue for egg allRewards
// Configure outro dialogue for egg rewards
encounter.dialogue.outro = [
{
speaker: trainerNameKey,
@ -422,7 +422,7 @@ export const TheExpertPokemonBreederEncounter: MysteryEncounter = MysteryEncount
// Remove all Pokemon from the party except the chosen Pokemon
removePokemonFromPartyAndStoreHeldItems(encounter, pokemon3);
// Configure outro dialogue for egg allRewards
// Configure outro dialogue for egg rewards
encounter.dialogue.outro = [
{
speaker: trainerNameKey,
@ -640,7 +640,7 @@ function onGameOver() {
const chosenPokemon = encounter.misc.chosenPokemon;
chosenPokemon.friendship = 0;
// Clear all allRewards that would have been earned
// Clear all rewards that would have been earned
encounter.doEncounterRewards = undefined;
// Set flag that encounter was failed

View File

@ -1,7 +1,6 @@
import { applyAbAttrs } from "#abilities/apply-ab-attrs";
import { CLASSIC_MODE_MYSTERY_ENCOUNTER_WAVES } from "#app/constants";
import { globalScene } from "#app/global-scene";
import { allRewards } from "#data/data-lists";
import { SpeciesFormChangeAbilityTrigger } from "#data/form-change-triggers";
import { AbilityId } from "#enums/ability-id";
import { BattlerTagType } from "#enums/battler-tag-type";
@ -119,7 +118,7 @@ export const TheWinstrateChallengeEncounter: MysteryEncounter = MysteryEncounter
],
},
async () => {
// Spawn 5 trainer battles back to back with Macho Brace in allRewards
// Spawn 5 trainer battles back to back with Macho Brace in rewards
globalScene.currentBattle.mysteryEncounter!.doContinueEncounter = async () => {
await endTrainerBattleAndShowDialogue();
};
@ -158,13 +157,13 @@ async function spawnNextTrainerOrEndEncounter() {
await showEncounterDialogue(`${namespace}:victory`, `${namespace}:speaker`);
// Give 10x Voucher
const reward = allRewards[RewardId.VOUCHER_PREMIUM]();
const reward = generateRewardOptionFromId(RewardId.VOUCHER_PREMIUM).type;
globalScene.applyReward(reward as Reward, {});
globalScene.playSound("item_fanfare");
await showEncounterText(i18next.t("battle:rewardGain", { modifierName: (reward as Reward).name }));
await showEncounterDialogue(`${namespace}:victory_2`, `${namespace}:speaker`);
globalScene.ui.clearText(); // Clears "Winstrate" title from screen as allRewards get animated in
globalScene.ui.clearText(); // Clears "Winstrate" title from screen as rewards get animated in
const machoBrace = generateRewardOptionFromId(HeldItemId.MACHO_BRACE)!;
machoBrace.type.tier = RarityTier.MASTER;
setEncounterRewards({

View File

@ -174,11 +174,11 @@ export class MysteryEncounter implements IMysteryEncounter {
onVisualsStart?: () => boolean;
/** Event triggered prior to {@linkcode CommandPhase}, during {@linkcode TurnInitPhase} */
onTurnStart?: () => boolean;
/** Event prior to any allRewards logic in {@linkcode MysteryEncounterRewardsPhase} */
/** Event prior to any reward logic in {@linkcode MysteryEncounterRewardsPhase} */
onRewards?: () => Promise<void>;
/** Will provide the player party EXP before allRewards are displayed for that wave */
/** Will provide the player party EXP before rewards are displayed for that wave */
doEncounterExp?: () => boolean;
/** Will provide the player a allRewards shop for that wave */
/** Will provide the player a reward shop for that wave */
doEncounterRewards?: () => boolean;
/** Will execute callback during VictoryPhase of a continuousEncounter */
doContinueEncounter?: () => Promise<void>;
@ -238,7 +238,7 @@ export class MysteryEncounter implements IMysteryEncounter {
encounterMode: MysteryEncounterMode;
/**
* Flag for checking if it's the first time a shop is being shown for an encounter.
* Defaults to true so that the first shop does not override the specified allRewards.
* Defaults to true so that the first shop does not override the specified rewards.
* Will be set to false after a shop is shown (so can't reroll same rarity items for free)
*/
lockEncounterRarityTiers: boolean;
@ -928,34 +928,6 @@ export class MysteryEncounterBuilder implements Partial<IMysteryEncounter> {
});
}
/**
* Can set custom encounter allRewards via this callback function
* If allRewards are always deterministic for an encounter, this is a good way to set them
*
* NOTE: If allRewards are dependent on options selected, runtime data, etc.,
* It may be better to programmatically set doEncounterRewards elsewhere.
* There is a helper function in mystery-encounter utils, setEncounterRewards(), which can be called programmatically to set allRewards
* @param doEncounterRewards Synchronous callback function to perform during allRewards phase of the encounter
* @returns
*/
withRewards(doEncounterRewards: () => boolean): this & Required<Pick<IMysteryEncounter, "doEncounterRewards">> {
return Object.assign(this, { doEncounterRewards: doEncounterRewards });
}
/**
* Can set custom encounter exp via this callback function
* If exp always deterministic for an encounter, this is a good way to set them
*
* NOTE: If allRewards are dependent on options selected, runtime data, etc.,
* It may be better to programmatically set doEncounterExp elsewhere.
* There is a helper function in mystery-encounter utils, setEncounterExp(), which can be called programmatically to set allRewards
* @param doEncounterExp Synchronous callback function to perform during allRewards phase of the encounter
* @returns
*/
withExp(doEncounterExp: () => boolean): this & Required<Pick<IMysteryEncounter, "doEncounterExp">> {
return Object.assign(this, { doEncounterExp: doEncounterExp });
}
/**
* Can be used to perform init logic before intro visuals are shown and before the MysteryEncounterPhase begins
* Useful for performing things like procedural generation of intro sprites, etc.

View File

@ -686,7 +686,7 @@ export function selectOptionThenPokemon(
/**
* Will initialize reward phases to follow the mystery encounter
* Can have shop displayed or skipped
* @param customShopRewards - adds a shop phase with the specified allRewards / reward tiers
* @param customShopRewards - adds a shop phase with the specified reward tiers
* @param eggRewards
* @param preRewardsCallback - can execute an arbitrary callback before the new phases if necessary (useful for updating items/party/injecting new phases before {@linkcode MysteryEncounterRewardsPhase})
*/
@ -768,8 +768,8 @@ export function initSubsequentOptionSelect(optionSelectSettings: OptionSelectSet
/**
* Can be used to exit an encounter without any battles or followup
* Will skip any shops and allRewards, and queue the next encounter phase as normal
* @param addHealPhase - when true, will add a shop phase to end of encounter with 0 allRewards but healing items are available
* Will skip any shops and rewards, and queue the next encounter phase as normal
* @param addHealPhase - when true, will add a shop phase to end of encounter with 0 rewards but healing items are available
* @param encounterMode - Can set custom encounter mode if necessary (may be required for forcing Pokemon to return before next phase)
*/
export function leaveEncounterWithoutBattle(

View File

@ -79,9 +79,8 @@ export abstract class ItemTransferHeldItem extends HeldItem {
}
/**
* Modifier for held items that steal items from the enemy at the end of
* Held item that steal items from the enemy at the end of
* each turn.
* @see {@linkcode allRewards[MINI_BLACK_HOLE]}
*/
export class TurnEndItemStealHeldItem extends ItemTransferHeldItem {
public effects: HeldItemEffect[] = [HeldItemEffect.TURN_END_ITEM_STEAL];
@ -120,10 +119,8 @@ export class TurnEndItemStealHeldItem extends ItemTransferHeldItem {
}
/**
* Modifier for held items that add a chance to steal items from the target of a
* Held item that adds a chance to steal items from the target of a
* successful attack.
* @see {@linkcode allRewards[GRIP_CLAW]}
* @see {@linkcode HeldItemTransferModifier}
*/
export class ContactItemStealChanceHeldItem extends ItemTransferHeldItem {
public effects: HeldItemEffect[] = [HeldItemEffect.CONTACT_ITEM_STEAL_CHANCE];

View File

@ -2,11 +2,11 @@ import { pokerogueApi } from "#api/pokerogue-api";
import { clientSessionId } from "#app/account";
import { globalScene } from "#app/global-scene";
import { pokemonEvolutions } from "#balance/pokemon-evolutions";
import { allRewards } from "#data/data-lists";
import { getCharVariantFromDialogue } from "#data/dialogue";
import type { PokemonSpecies } from "#data/pokemon-species";
import { BattleType } from "#enums/battle-type";
import { PlayerGender } from "#enums/player-gender";
import { RewardId } from "#enums/reward-id";
import { TrainerType } from "#enums/trainer-type";
import { UiMode } from "#enums/ui-mode";
import { Unlockables } from "#enums/unlockables";
@ -151,10 +151,10 @@ export class GameOverPhase extends BattlePhase {
this.handleUnlocks();
for (const species of this.firstRibbons) {
globalScene.phaseManager.unshiftNew("RibbonRewardPhase", allRewards.VOUCHER_PLUS, species);
globalScene.phaseManager.unshiftNew("RibbonRewardPhase", RewardId.VOUCHER_PLUS, species);
}
if (!firstClear) {
globalScene.phaseManager.unshiftNew("GameOverRewardPhase", allRewards.VOUCHER_PREMIUM);
globalScene.phaseManager.unshiftNew("GameOverRewardPhase", RewardId.VOUCHER_PREMIUM);
}
}
this.getRunHistoryEntry().then(runHistoryEntry => {

View File

@ -532,13 +532,13 @@ export class MysteryEncounterRewardsPhase extends Phase {
} else {
this.doEncounterRewardsAndContinue();
}
// Do not use ME's seedOffset for allRewards, these should always be consistent with waveIndex (once per wave)
// Do not use ME's seedOffset for rewards, these should always be consistent with waveIndex (once per wave)
}, globalScene.currentBattle.waveIndex * 1000);
}
}
/**
* Queues encounter EXP and allRewards phases, {@linkcode PostMysteryEncounterPhase}, and ends phase
* Queues encounter EXP and reward phases, {@linkcode PostMysteryEncounterPhase}, and ends phase
*/
doEncounterRewardsAndContinue() {
const encounter = globalScene.currentBattle.mysteryEncounter!;

View File

@ -108,7 +108,7 @@ export class SelectRewardPhase extends BattlePhase {
default:
return false;
}
// Pick an option from the allRewards
// Pick an option from the rewards
case 1:
return this.selectRewardOption(cursor, rewardSelectCallback);
// Pick an option from the shop
@ -121,7 +121,7 @@ export class SelectRewardPhase extends BattlePhase {
this.resetRewardSelect(rewardSelectCallback);
}
// Pick a reward from among the allRewards and apply it
// Pick a reward from among the rewards and apply it
private selectRewardOption(cursor: number, rewardSelectCallback: RewardSelectCallback): boolean {
if (this.typeOptions.length === 0) {
globalScene.ui.clearText();
@ -175,7 +175,6 @@ export class SelectRewardPhase extends BattlePhase {
return cost === -1;
}
// Reroll allRewards
private rerollRewards() {
const rerollCost = this.getRerollCost(globalScene.lockRarityTiers);
if (rerollCost < 0 || globalScene.money < rerollCost) {

View File

@ -59,7 +59,7 @@ export class VictoryPhase extends PokemonPhase {
.map(r => globalScene.phaseManager.pushNew("RewardPhase", r));
break;
case ClassicFixedBossWaves.EVIL_BOSS_2:
// Should get Lock Capsule on 165 before shop phase so it can be used in the allRewards shop
// Should get Lock Capsule on 165 before shop phase so it can be used in the reward shop
globalScene.phaseManager.pushNew("RewardPhase", TrainerItemId.LOCK_CAPSULE);
break;
}
@ -124,7 +124,7 @@ export class VictoryPhase extends PokemonPhase {
}
/**
* If this wave is a fixed battle with special custom modifier allRewards,
* If this wave is a fixed battle with special custom rewards,
* will pass those settings to the upcoming {@linkcode SelectRewardPhase}`.
*/
getFixedBattleCustomRewards(): CustomRewardSettings | undefined {

View File

@ -67,7 +67,7 @@ interface TimedEvent extends EventBanner {
mysteryEncounterTierChanges?: EventMysteryEncounterTier[];
luckBoostedSpecies?: SpeciesId[];
boostFusions?: boolean; //MODIFIER REWORK PLEASE
classicWaveRewards?: EventWaveReward[]; // Rival battle allRewards
classicWaveRewards?: EventWaveReward[]; // Rival battle rewards
trainerShinyChance?: number; // Odds over 65536 of trainer mon generating as shiny
music?: EventMusicReplacement[];
dailyRunChallenges?: EventChallenge[];
@ -569,8 +569,8 @@ export class TimedEventManager {
/**
* Gets all the modifier types associated with a certain wave during an event
* @see EventWaveReward
* @param wave the wave to check for associated allRewards
* @returns array of strings of the event modifier reward types
* @param wave the wave to check for associated rewards
* @returns array of strings of the event reward types
*/
getFixedBattleEventRewards(wave: number): SilentReward[] {
const ret: SilentReward[] = [];