mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-01 14:02:18 +02:00
Merge branch 'beta' into intim-tests
This commit is contained in:
commit
3b45544ebf
4
package-lock.json
generated
4
package-lock.json
generated
@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "pokemon-rogue-battle",
|
||||
"version": "1.9.4",
|
||||
"version": "1.9.5",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "pokemon-rogue-battle",
|
||||
"version": "1.9.4",
|
||||
"version": "1.9.5",
|
||||
"hasInstallScript": true,
|
||||
"dependencies": {
|
||||
"@material/material-color-utilities": "^0.2.7",
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "pokemon-rogue-battle",
|
||||
"private": true,
|
||||
"version": "1.9.4",
|
||||
"version": "1.9.5",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"start": "vite",
|
||||
|
@ -581,7 +581,7 @@ function calculateEggRewardsForPokemon(pokemon: PlayerPokemon): [number, number]
|
||||
}
|
||||
|
||||
function getEggOptions(commonEggs: number, rareEggs: number) {
|
||||
const eggDescription = i18next.t(`${namespace}:title`) + ":\n" + i18next.t(trainerNameKey);
|
||||
const eggDescription = i18next.t(`${namespace}:title`);
|
||||
const eggOptions: IEggOptions[] = [];
|
||||
|
||||
if (commonEggs > 0) {
|
||||
|
@ -447,12 +447,14 @@ export default abstract class BattleInfo extends Phaser.GameObjects.Container {
|
||||
}
|
||||
|
||||
/** Update the pokemon name inside the container */
|
||||
protected updateName(name: string): boolean {
|
||||
protected updateName(pokemon: Pokemon): boolean {
|
||||
const name = pokemon.getNameToRender();
|
||||
if (this.lastName === name) {
|
||||
return false;
|
||||
}
|
||||
this.nameText.setText(name).setPositionRelative(this.box, -this.nameText.displayWidth, 0);
|
||||
this.lastName = name;
|
||||
|
||||
this.updateNameText(pokemon);
|
||||
this.genderText.setPositionRelative(this.nameText, this.nameText.displayWidth, 0);
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -572,7 +574,7 @@ export default abstract class BattleInfo extends Phaser.GameObjects.Container {
|
||||
|
||||
this.genderText.setText(getGenderSymbol(gender)).setColor(getGenderColor(gender));
|
||||
|
||||
const nameUpdated = this.updateName(pokemon.getNameToRender());
|
||||
const nameUpdated = this.updateName(pokemon);
|
||||
|
||||
const teraTypeUpdated = this.updateTeraType(pokemon.isTerastallized ? pokemon.getTeraType() : PokemonType.UNKNOWN);
|
||||
|
||||
@ -584,6 +586,8 @@ export default abstract class BattleInfo extends Phaser.GameObjects.Container {
|
||||
|
||||
this.updateStatusIcon(pokemon);
|
||||
|
||||
this.setTypes(pokemon.getTypes(true, false, undefined, true));
|
||||
|
||||
if (this.lastHp !== pokemon.hp || this.lastMaxHp !== pokemon.getMaxHp()) {
|
||||
return this.updatePokemonHp(pokemon, resolve, instant);
|
||||
}
|
||||
|
@ -33,7 +33,7 @@ enum MenuOptions {
|
||||
}
|
||||
|
||||
let wikiUrl = "https://wiki.pokerogue.net/start";
|
||||
const discordUrl = "https://discord.gg/uWpTfdKG49";
|
||||
const discordUrl = "https://discord.gg/pokerogue";
|
||||
const githubUrl = "https://github.com/pagefaultgames/pokerogue";
|
||||
const redditUrl = "https://www.reddit.com/r/pokerogue";
|
||||
const donateUrl = "https://github.com/sponsors/pagefaultgames";
|
||||
|
@ -167,7 +167,12 @@ describe("Moves - Last Respects", () => {
|
||||
game.move.select(Moves.LAST_RESPECTS);
|
||||
await game.setTurnOrder([BattlerIndex.ENEMY, BattlerIndex.PLAYER]);
|
||||
await game.phaseInterceptor.to("MoveEndPhase");
|
||||
expect(move.calculateBattlePower).toHaveLastReturnedWith(basePower);
|
||||
|
||||
const enemy = game.field.getEnemyPokemon();
|
||||
const player = game.field.getPlayerPokemon();
|
||||
const items = `Player items: ${player.getHeldItems()} | Enemy Items: ${enemy.getHeldItems()} |`;
|
||||
|
||||
expect(move.calculateBattlePower, items).toHaveLastReturnedWith(50);
|
||||
});
|
||||
|
||||
it("should reset playerFaints count if we enter new trainer battle", async () => {
|
||||
|
Loading…
Reference in New Issue
Block a user