mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-01 14:02:18 +02:00
Merge branch 'beta' of https://github.com/pagefaultgames/pokerogue into evcndrf2
This commit is contained in:
commit
459d43c3bf
@ -10,14 +10,14 @@ import { Biome } from "#enums/biome";
|
|||||||
import { Moves } from "#enums/moves";
|
import { Moves } from "#enums/moves";
|
||||||
import { Species } from "#enums/species";
|
import { Species } from "#enums/species";
|
||||||
import { TimeOfDay } from "#enums/time-of-day";
|
import { TimeOfDay } from "#enums/time-of-day";
|
||||||
import { EvoTrackerModifier, EvoTrackerMoveUseModifier, EvoTrackerRecoilModifier, PersistentModifier} from "#app/modifier/modifier";
|
import { EvoTrackerModifier, EvoTrackerMoveUseModifier, EvoTrackerRecoilModifier, SpeciesStatBoosterModifier, PersistentModifier} from "#app/modifier/modifier";
|
||||||
import { SpeciesFormKey } from "#enums/species-form-key";
|
import { SpeciesFormKey } from "#enums/species-form-key";
|
||||||
|
import type { SpeciesStatBoosterModifierType } from "#app/modifier/modifier-type";
|
||||||
import { speciesStarterCosts } from "./starters";
|
import { speciesStarterCosts } from "./starters";
|
||||||
import i18next from "i18next";
|
import i18next from "i18next";
|
||||||
import { allMoves } from "#app/data/data-lists";
|
import { allMoves } from "#app/data/data-lists";
|
||||||
import { getPokemonSpecies } from "../pokemon-species";
|
import { getPokemonSpecies } from "../pokemon-species";
|
||||||
|
|
||||||
|
|
||||||
export enum SpeciesWildEvolutionDelay {
|
export enum SpeciesWildEvolutionDelay {
|
||||||
NONE,
|
NONE,
|
||||||
SHORT,
|
SHORT,
|
||||||
@ -1785,8 +1785,9 @@ export const pokemonEvolutions: PokemonEvolutions = {
|
|||||||
new SpeciesEvolution(Species.DUSKNOIR, 1, EvolutionItem.REAPER_CLOTH, null, SpeciesWildEvolutionDelay.VERY_LONG)
|
new SpeciesEvolution(Species.DUSKNOIR, 1, EvolutionItem.REAPER_CLOTH, null, SpeciesWildEvolutionDelay.VERY_LONG)
|
||||||
],
|
],
|
||||||
[Species.CLAMPERL]: [
|
[Species.CLAMPERL]: [
|
||||||
new SpeciesEvolution(Species.HUNTAIL, 1, EvolutionItem.LINKING_CORD, {key: EvoCondKey.GENDER, gender: Gender.MALE/* Deep Sea Tooth */}, SpeciesWildEvolutionDelay.VERY_LONG),
|
// TODO: Change the SpeciesEvolutionConditions here to use a bespoke HeldItemEvolutionCondition after the modifier rework
|
||||||
new SpeciesEvolution(Species.GOREBYSS, 1, EvolutionItem.LINKING_CORD, {key: EvoCondKey.GENDER, gender: Gender.FEMALE/* Deep Sea Scale */}, SpeciesWildEvolutionDelay.VERY_LONG)
|
new SpeciesEvolution(Species.HUNTAIL, 1, EvolutionItem.LINKING_CORD, {}, SpeciesWildEvolutionDelay.VERY_LONG),
|
||||||
|
new SpeciesEvolution(Species.GOREBYSS, 1, EvolutionItem.LINKING_CORD, {}, SpeciesWildEvolutionDelay.VERY_LONG)
|
||||||
],
|
],
|
||||||
[Species.BOLDORE]: [
|
[Species.BOLDORE]: [
|
||||||
new SpeciesEvolution(Species.GIGALITH, 1, EvolutionItem.LINKING_CORD, null, SpeciesWildEvolutionDelay.VERY_LONG)
|
new SpeciesEvolution(Species.GIGALITH, 1, EvolutionItem.LINKING_CORD, null, SpeciesWildEvolutionDelay.VERY_LONG)
|
||||||
|
@ -875,7 +875,7 @@ export class SpeciesStatBoosterModifierType
|
|||||||
extends PokemonHeldItemModifierType
|
extends PokemonHeldItemModifierType
|
||||||
implements GeneratedPersistentModifierType
|
implements GeneratedPersistentModifierType
|
||||||
{
|
{
|
||||||
private key: SpeciesStatBoosterItem;
|
public key: SpeciesStatBoosterItem;
|
||||||
|
|
||||||
constructor(key: SpeciesStatBoosterItem) {
|
constructor(key: SpeciesStatBoosterItem) {
|
||||||
const item = SpeciesStatBoosterModifierTypeGenerator.items[key];
|
const item = SpeciesStatBoosterModifierTypeGenerator.items[key];
|
||||||
@ -1438,34 +1438,59 @@ class SpeciesStatBoosterModifierTypeGenerator extends ModifierTypeGenerator {
|
|||||||
stats: [Stat.ATK, Stat.SPATK],
|
stats: [Stat.ATK, Stat.SPATK],
|
||||||
multiplier: 2,
|
multiplier: 2,
|
||||||
species: [Species.PIKACHU],
|
species: [Species.PIKACHU],
|
||||||
|
rare: true,
|
||||||
},
|
},
|
||||||
THICK_CLUB: {
|
THICK_CLUB: {
|
||||||
stats: [Stat.ATK],
|
stats: [Stat.ATK],
|
||||||
multiplier: 2,
|
multiplier: 2,
|
||||||
species: [Species.CUBONE, Species.MAROWAK, Species.ALOLA_MAROWAK],
|
species: [Species.CUBONE, Species.MAROWAK, Species.ALOLA_MAROWAK],
|
||||||
|
rare: true,
|
||||||
},
|
},
|
||||||
METAL_POWDER: {
|
METAL_POWDER: {
|
||||||
stats: [Stat.DEF],
|
stats: [Stat.DEF],
|
||||||
multiplier: 2,
|
multiplier: 2,
|
||||||
species: [Species.DITTO],
|
species: [Species.DITTO],
|
||||||
|
rare: true,
|
||||||
},
|
},
|
||||||
QUICK_POWDER: {
|
QUICK_POWDER: {
|
||||||
stats: [Stat.SPD],
|
stats: [Stat.SPD],
|
||||||
multiplier: 2,
|
multiplier: 2,
|
||||||
species: [Species.DITTO],
|
species: [Species.DITTO],
|
||||||
|
rare: true,
|
||||||
|
},
|
||||||
|
DEEP_SEA_SCALE: {
|
||||||
|
stats: [Stat.SPDEF],
|
||||||
|
multiplier: 2,
|
||||||
|
species: [Species.CLAMPERL],
|
||||||
|
rare: false,
|
||||||
|
},
|
||||||
|
DEEP_SEA_TOOTH: {
|
||||||
|
stats: [Stat.SPATK],
|
||||||
|
multiplier: 2,
|
||||||
|
species: [Species.CLAMPERL],
|
||||||
|
rare: false,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
constructor() {
|
constructor(rare: boolean) {
|
||||||
super((party: Pokemon[], pregenArgs?: any[]) => {
|
super((party: Pokemon[], pregenArgs?: any[]) => {
|
||||||
const items = SpeciesStatBoosterModifierTypeGenerator.items;
|
const items = SpeciesStatBoosterModifierTypeGenerator.items;
|
||||||
if (pregenArgs && pregenArgs.length === 1 && pregenArgs[0] in items) {
|
if (pregenArgs && pregenArgs.length === 1 && pregenArgs[0] in items) {
|
||||||
return new SpeciesStatBoosterModifierType(pregenArgs[0] as SpeciesStatBoosterItem);
|
return new SpeciesStatBoosterModifierType(pregenArgs[0] as SpeciesStatBoosterItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
const values = Object.values(items);
|
// Get a pool of items based on the rarity.
|
||||||
const keys = Object.keys(items);
|
const keys: (keyof SpeciesStatBoosterItem)[] = [];
|
||||||
const weights = keys.map(() => 0);
|
const values: (typeof items)[keyof typeof items][] = [];
|
||||||
|
const weights: number[] = [];
|
||||||
|
for (const [key, val] of Object.entries(SpeciesStatBoosterModifierTypeGenerator.items)) {
|
||||||
|
if (val.rare !== rare) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
values.push(val);
|
||||||
|
keys.push(key as keyof SpeciesStatBoosterItem);
|
||||||
|
weights.push(0);
|
||||||
|
}
|
||||||
|
|
||||||
for (const p of party) {
|
for (const p of party) {
|
||||||
const speciesId = p.getSpeciesForm(true).speciesId;
|
const speciesId = p.getSpeciesForm(true).speciesId;
|
||||||
@ -1840,7 +1865,7 @@ export type GeneratorModifierOverride = {
|
|||||||
count?: number;
|
count?: number;
|
||||||
} & (
|
} & (
|
||||||
| {
|
| {
|
||||||
name: keyof Pick<typeof modifierTypes, "SPECIES_STAT_BOOSTER">;
|
name: keyof Pick<typeof modifierTypes, "SPECIES_STAT_BOOSTER" | "RARE_SPECIES_STAT_BOOSTER">;
|
||||||
type?: SpeciesStatBoosterItem;
|
type?: SpeciesStatBoosterItem;
|
||||||
}
|
}
|
||||||
| {
|
| {
|
||||||
@ -1868,7 +1893,7 @@ export type GeneratorModifierOverride = {
|
|||||||
type?: EvolutionItem;
|
type?: EvolutionItem;
|
||||||
}
|
}
|
||||||
| {
|
| {
|
||||||
name: keyof Pick<typeof modifierTypes, "FORM_CHANGE_ITEM">;
|
name: keyof Pick<typeof modifierTypes, "FORM_CHANGE_ITEM" | "RARE_FORM_CHANGE_ITEM">;
|
||||||
type?: FormChangeItem;
|
type?: FormChangeItem;
|
||||||
}
|
}
|
||||||
| {
|
| {
|
||||||
@ -1992,7 +2017,8 @@ export const modifierTypes = {
|
|||||||
SUPER_LURE: () => new DoubleBattleChanceBoosterModifierType("modifierType:ModifierType.SUPER_LURE", "super_lure", 15),
|
SUPER_LURE: () => new DoubleBattleChanceBoosterModifierType("modifierType:ModifierType.SUPER_LURE", "super_lure", 15),
|
||||||
MAX_LURE: () => new DoubleBattleChanceBoosterModifierType("modifierType:ModifierType.MAX_LURE", "max_lure", 30),
|
MAX_LURE: () => new DoubleBattleChanceBoosterModifierType("modifierType:ModifierType.MAX_LURE", "max_lure", 30),
|
||||||
|
|
||||||
SPECIES_STAT_BOOSTER: () => new SpeciesStatBoosterModifierTypeGenerator(),
|
SPECIES_STAT_BOOSTER: () => new SpeciesStatBoosterModifierTypeGenerator(false),
|
||||||
|
RARE_SPECIES_STAT_BOOSTER: () => new SpeciesStatBoosterModifierTypeGenerator(true),
|
||||||
|
|
||||||
TEMP_STAT_STAGE_BOOSTER: () => new TempStatStageBoosterModifierTypeGenerator(),
|
TEMP_STAT_STAGE_BOOSTER: () => new TempStatStageBoosterModifierTypeGenerator(),
|
||||||
|
|
||||||
@ -2632,6 +2658,7 @@ const modifierPool: ModifierPool = {
|
|||||||
new WeightedModifierType(modifierTypes.DIRE_HIT, 4),
|
new WeightedModifierType(modifierTypes.DIRE_HIT, 4),
|
||||||
new WeightedModifierType(modifierTypes.SUPER_LURE, lureWeightFunc(15, 4)),
|
new WeightedModifierType(modifierTypes.SUPER_LURE, lureWeightFunc(15, 4)),
|
||||||
new WeightedModifierType(modifierTypes.NUGGET, skipInLastClassicWaveOrDefault(5)),
|
new WeightedModifierType(modifierTypes.NUGGET, skipInLastClassicWaveOrDefault(5)),
|
||||||
|
new WeightedModifierType(modifierTypes.SPECIES_STAT_BOOSTER, 4),
|
||||||
new WeightedModifierType(
|
new WeightedModifierType(
|
||||||
modifierTypes.EVOLUTION_ITEM,
|
modifierTypes.EVOLUTION_ITEM,
|
||||||
() => {
|
() => {
|
||||||
@ -2728,7 +2755,7 @@ const modifierPool: ModifierPool = {
|
|||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}),
|
}),
|
||||||
new WeightedModifierType(modifierTypes.SPECIES_STAT_BOOSTER, 12),
|
new WeightedModifierType(modifierTypes.RARE_SPECIES_STAT_BOOSTER, 12),
|
||||||
new WeightedModifierType(
|
new WeightedModifierType(
|
||||||
modifierTypes.LEEK,
|
modifierTypes.LEEK,
|
||||||
(party: Pokemon[]) => {
|
(party: Pokemon[]) => {
|
||||||
|
@ -32,7 +32,7 @@ export default class BallUiHandler extends UiHandler {
|
|||||||
for (let pb = 0; pb < Object.keys(globalScene.pokeballCounts).length; pb++) {
|
for (let pb = 0; pb < Object.keys(globalScene.pokeballCounts).length; pb++) {
|
||||||
optionsTextContent += `${getPokeballName(pb)}\n`;
|
optionsTextContent += `${getPokeballName(pb)}\n`;
|
||||||
}
|
}
|
||||||
optionsTextContent += i18next.t("pokeball:cancel");
|
optionsTextContent += i18next.t("commandUiHandler:ballCancel");
|
||||||
const optionsText = addTextObject(0, 0, optionsTextContent, TextStyle.WINDOW, { align: "right", maxLines: 6 });
|
const optionsText = addTextObject(0, 0, optionsTextContent, TextStyle.WINDOW, { align: "right", maxLines: 6 });
|
||||||
const optionsTextWidth = optionsText.displayWidth;
|
const optionsTextWidth = optionsText.displayWidth;
|
||||||
this.pokeballSelectContainer = globalScene.add.container(
|
this.pokeballSelectContainer = globalScene.add.container(
|
||||||
|
@ -29,7 +29,7 @@ describe("Items - Light Ball", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("LIGHT_BALL activates in battle correctly", async () => {
|
it("LIGHT_BALL activates in battle correctly", async () => {
|
||||||
game.override.startingHeldItems([{ name: "SPECIES_STAT_BOOSTER", type: "LIGHT_BALL" }]);
|
game.override.startingHeldItems([{ name: "RARE_SPECIES_STAT_BOOSTER", type: "LIGHT_BALL" }]);
|
||||||
const consoleSpy = vi.spyOn(console, "log");
|
const consoleSpy = vi.spyOn(console, "log");
|
||||||
await game.classicMode.startBattle([Species.PIKACHU]);
|
await game.classicMode.startBattle([Species.PIKACHU]);
|
||||||
|
|
||||||
@ -100,7 +100,7 @@ describe("Items - Light Ball", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -139,7 +139,7 @@ describe("Items - Light Ball", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -178,7 +178,7 @@ describe("Items - Light Ball", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -207,7 +207,7 @@ describe("Items - Light Ball", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["LIGHT_BALL"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
|
@ -29,7 +29,7 @@ describe("Items - Metal Powder", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("METAL_POWDER activates in battle correctly", async () => {
|
it("METAL_POWDER activates in battle correctly", async () => {
|
||||||
game.override.startingHeldItems([{ name: "SPECIES_STAT_BOOSTER", type: "METAL_POWDER" }]);
|
game.override.startingHeldItems([{ name: "RARE_SPECIES_STAT_BOOSTER", type: "METAL_POWDER" }]);
|
||||||
const consoleSpy = vi.spyOn(console, "log");
|
const consoleSpy = vi.spyOn(console, "log");
|
||||||
await game.classicMode.startBattle([Species.DITTO]);
|
await game.classicMode.startBattle([Species.DITTO]);
|
||||||
|
|
||||||
@ -96,7 +96,7 @@ describe("Items - Metal Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
||||||
@ -129,7 +129,7 @@ describe("Items - Metal Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
||||||
@ -162,7 +162,7 @@ describe("Items - Metal Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
||||||
@ -185,7 +185,7 @@ describe("Items - Metal Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["METAL_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.DEF, defValue);
|
||||||
|
@ -29,7 +29,7 @@ describe("Items - Quick Powder", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("QUICK_POWDER activates in battle correctly", async () => {
|
it("QUICK_POWDER activates in battle correctly", async () => {
|
||||||
game.override.startingHeldItems([{ name: "SPECIES_STAT_BOOSTER", type: "QUICK_POWDER" }]);
|
game.override.startingHeldItems([{ name: "RARE_SPECIES_STAT_BOOSTER", type: "QUICK_POWDER" }]);
|
||||||
const consoleSpy = vi.spyOn(console, "log");
|
const consoleSpy = vi.spyOn(console, "log");
|
||||||
await game.classicMode.startBattle([Species.DITTO]);
|
await game.classicMode.startBattle([Species.DITTO]);
|
||||||
|
|
||||||
@ -96,7 +96,7 @@ describe("Items - Quick Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
||||||
@ -129,7 +129,7 @@ describe("Items - Quick Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
||||||
@ -162,7 +162,7 @@ describe("Items - Quick Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
||||||
@ -185,7 +185,7 @@ describe("Items - Quick Powder", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["QUICK_POWDER"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.SPD, spdValue);
|
||||||
|
@ -29,7 +29,7 @@ describe("Items - Thick Club", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("THICK_CLUB activates in battle correctly", async () => {
|
it("THICK_CLUB activates in battle correctly", async () => {
|
||||||
game.override.startingHeldItems([{ name: "SPECIES_STAT_BOOSTER", type: "THICK_CLUB" }]);
|
game.override.startingHeldItems([{ name: "RARE_SPECIES_STAT_BOOSTER", type: "THICK_CLUB" }]);
|
||||||
const consoleSpy = vi.spyOn(console, "log");
|
const consoleSpy = vi.spyOn(console, "log");
|
||||||
await game.classicMode.startBattle([Species.CUBONE]);
|
await game.classicMode.startBattle([Species.CUBONE]);
|
||||||
|
|
||||||
@ -96,7 +96,7 @@ describe("Items - Thick Club", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -119,7 +119,7 @@ describe("Items - Thick Club", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -142,7 +142,7 @@ describe("Items - Thick Club", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -179,7 +179,7 @@ describe("Items - Thick Club", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -216,7 +216,7 @@ describe("Items - Thick Club", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
@ -239,7 +239,7 @@ describe("Items - Thick Club", () => {
|
|||||||
|
|
||||||
// Giving Eviolite to party member and testing if it applies
|
// Giving Eviolite to party member and testing if it applies
|
||||||
await game.scene.addModifier(
|
await game.scene.addModifier(
|
||||||
modifierTypes.SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
modifierTypes.RARE_SPECIES_STAT_BOOSTER().generateType([], ["THICK_CLUB"])!.newModifier(partyMember),
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
game.scene.applyModifiers(SpeciesStatBoosterModifier, true, partyMember, Stat.ATK, atkValue);
|
||||||
|
Loading…
Reference in New Issue
Block a user