mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-04 15:32:18 +02:00
Merge branch 'pagefaultgames:main' into main
This commit is contained in:
commit
f8cf3834b8
@ -3562,9 +3562,9 @@ export function initMoves() {
|
|||||||
.attr(AddBattlerTagAttr, BattlerTagType.ENCORE, false, true)
|
.attr(AddBattlerTagAttr, BattlerTagType.ENCORE, false, true)
|
||||||
.condition((user, target, move) => new EncoreTag(user.id).canAdd(target)),
|
.condition((user, target, move) => new EncoreTag(user.id).canAdd(target)),
|
||||||
new AttackMove(Moves.PURSUIT, "Pursuit (P)", Type.DARK, MoveCategory.PHYSICAL, 40, 100, 20, "The power of this attack move is doubled if it's used on a target that's switching out of battle.", -1, 0, 2),
|
new AttackMove(Moves.PURSUIT, "Pursuit (P)", Type.DARK, MoveCategory.PHYSICAL, 40, 100, 20, "The power of this attack move is doubled if it's used on a target that's switching out of battle.", -1, 0, 2),
|
||||||
new AttackMove(Moves.RAPID_SPIN, "Rapid Spin", Type.NORMAL, MoveCategory.PHYSICAL, 50, 100, 40, "A spin attack that can also eliminate such moves as Bind, Wrap, and Leech Seed. This also raises the user's Speed stat.", 100, 0, 2)
|
new AttackMove(Moves.RAPID_SPIN, "Rapid Spin (P)", Type.NORMAL, MoveCategory.PHYSICAL, 50, 100, 40, "A spin attack that can also eliminate such moves as Bind, Wrap, and Leech Seed. This also raises the user's Speed stat.", 100, 0, 2)
|
||||||
.attr(StatChangeAttr, BattleStat.SPD, 1, true)
|
.attr(StatChangeAttr, BattleStat.SPD, 1, true)
|
||||||
.attr(LapseBattlerTagAttr, [ BattlerTagType.BIND, BattlerTagType.WRAP, BattlerTagType.FIRE_SPIN, BattlerTagType.WHIRLPOOL, BattlerTagType.CLAMP, BattlerTagType.SAND_TOMB, BattlerTagType.MAGMA_STORM, BattlerTagType.THUNDER_CAGE, BattlerTagType.SEEDED ], true),
|
.attr(RemoveBattlerTagAttr, [ BattlerTagType.BIND, BattlerTagType.WRAP, BattlerTagType.FIRE_SPIN, BattlerTagType.WHIRLPOOL, BattlerTagType.CLAMP, BattlerTagType.SAND_TOMB, BattlerTagType.MAGMA_STORM, BattlerTagType.THUNDER_CAGE, BattlerTagType.SEEDED ], true),
|
||||||
new StatusMove(Moves.SWEET_SCENT, "Sweet Scent", Type.NORMAL, 100, 20, "A sweet scent that harshly lowers opposing Pokémon's evasiveness.", -1, 0, 2)
|
new StatusMove(Moves.SWEET_SCENT, "Sweet Scent", Type.NORMAL, 100, 20, "A sweet scent that harshly lowers opposing Pokémon's evasiveness.", -1, 0, 2)
|
||||||
.attr(StatChangeAttr, BattleStat.EVA, -1)
|
.attr(StatChangeAttr, BattleStat.EVA, -1)
|
||||||
.target(MoveTarget.ALL_NEAR_ENEMIES),
|
.target(MoveTarget.ALL_NEAR_ENEMIES),
|
||||||
|
@ -351,7 +351,7 @@ export class EggHatchPhase extends Phase {
|
|||||||
|
|
||||||
if (speciesOverride) {
|
if (speciesOverride) {
|
||||||
const pokemonSpecies = getPokemonSpecies(speciesOverride);
|
const pokemonSpecies = getPokemonSpecies(speciesOverride);
|
||||||
ret = this.scene.addPlayerPokemon(pokemonSpecies, 5, undefined, undefined, undefined, false);
|
ret = this.scene.addPlayerPokemon(pokemonSpecies, 1, undefined, undefined, undefined, false);
|
||||||
} else {
|
} else {
|
||||||
let minStarterValue: integer;
|
let minStarterValue: integer;
|
||||||
let maxStarterValue: integer;
|
let maxStarterValue: integer;
|
||||||
@ -405,7 +405,7 @@ export class EggHatchPhase extends Phase {
|
|||||||
|
|
||||||
const pokemonSpecies = getPokemonSpecies(species);
|
const pokemonSpecies = getPokemonSpecies(species);
|
||||||
|
|
||||||
ret = this.scene.addPlayerPokemon(pokemonSpecies, 5, undefined, undefined, undefined, false);
|
ret = this.scene.addPlayerPokemon(pokemonSpecies, 1, undefined, undefined, undefined, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
ret.trySetShiny(this.egg.gachaType === GachaType.SHINY ? 1024 : 512);
|
ret.trySetShiny(this.egg.gachaType === GachaType.SHINY ? 1024 : 512);
|
||||||
|
@ -165,13 +165,15 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
|
|||||||
this.metBiome = scene.currentBattle ? scene.arena.biomeType : -1;
|
this.metBiome = scene.currentBattle ? scene.arena.biomeType : -1;
|
||||||
this.pokerus = false;
|
this.pokerus = false;
|
||||||
|
|
||||||
const fused = new Utils.BooleanHolder(scene.gameMode.isSplicedOnly);
|
if (level > 1) {
|
||||||
if (!fused.value && !this.isPlayer() && !this.hasTrainer())
|
const fused = new Utils.BooleanHolder(scene.gameMode.isSplicedOnly);
|
||||||
this.scene.applyModifier(EnemyFusionChanceModifier, false, fused);
|
if (!fused.value && !this.isPlayer() && !this.hasTrainer())
|
||||||
|
this.scene.applyModifier(EnemyFusionChanceModifier, false, fused);
|
||||||
|
|
||||||
if (fused.value) {
|
if (fused.value) {
|
||||||
this.calculateStats();
|
this.calculateStats();
|
||||||
this.generateFusionSpecies();
|
this.generateFusionSpecies();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -706,7 +708,7 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
|
|||||||
return allAbilities[ABILITY_OVERRIDE];
|
return allAbilities[ABILITY_OVERRIDE];
|
||||||
if (OPP_ABILITY_OVERRIDE && !this.isPlayer())
|
if (OPP_ABILITY_OVERRIDE && !this.isPlayer())
|
||||||
return allAbilities[OPP_ABILITY_OVERRIDE];
|
return allAbilities[OPP_ABILITY_OVERRIDE];
|
||||||
if (this.fusionSpecies)
|
if (this.isFusion())
|
||||||
return allAbilities[this.getFusionSpeciesForm().getAbility(this.fusionAbilityIndex)];
|
return allAbilities[this.getFusionSpeciesForm().getAbility(this.fusionAbilityIndex)];
|
||||||
let abilityId = this.getSpeciesForm().getAbility(this.abilityIndex);
|
let abilityId = this.getSpeciesForm().getAbility(this.abilityIndex);
|
||||||
if (abilityId === Abilities.NONE)
|
if (abilityId === Abilities.NONE)
|
||||||
|
@ -326,9 +326,9 @@ export class TitlePhase extends Phase {
|
|||||||
if (this.loaded) {
|
if (this.loaded) {
|
||||||
const availablePartyMembers = this.scene.getParty().filter(p => !p.isFainted()).length;
|
const availablePartyMembers = this.scene.getParty().filter(p => !p.isFainted()).length;
|
||||||
|
|
||||||
this.scene.pushPhase(new SummonPhase(this.scene, 0));
|
this.scene.pushPhase(new SummonPhase(this.scene, 0, true, true));
|
||||||
if (this.scene.currentBattle.double && availablePartyMembers > 1)
|
if (this.scene.currentBattle.double && availablePartyMembers > 1)
|
||||||
this.scene.pushPhase(new SummonPhase(this.scene, 1));
|
this.scene.pushPhase(new SummonPhase(this.scene, 1, true, true));
|
||||||
if (this.scene.currentBattle.waveIndex > 1 && this.scene.currentBattle.battleType !== BattleType.TRAINER) {
|
if (this.scene.currentBattle.waveIndex > 1 && this.scene.currentBattle.battleType !== BattleType.TRAINER) {
|
||||||
this.scene.pushPhase(new CheckSwitchPhase(this.scene, 0, this.scene.currentBattle.double));
|
this.scene.pushPhase(new CheckSwitchPhase(this.scene, 0, this.scene.currentBattle.double));
|
||||||
if (this.scene.currentBattle.double && availablePartyMembers > 1)
|
if (this.scene.currentBattle.double && availablePartyMembers > 1)
|
||||||
@ -1074,8 +1074,12 @@ export class SwitchBiomePhase extends BattlePhase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export class SummonPhase extends PartyMemberPokemonPhase {
|
export class SummonPhase extends PartyMemberPokemonPhase {
|
||||||
constructor(scene: BattleScene, fieldIndex: integer, player?: boolean) {
|
private loaded: boolean;
|
||||||
super(scene, fieldIndex, player !== undefined ? player : true);
|
|
||||||
|
constructor(scene: BattleScene, fieldIndex: integer, player: boolean = true, loaded: boolean = false) {
|
||||||
|
super(scene, fieldIndex, player);
|
||||||
|
|
||||||
|
this.loaded = loaded;
|
||||||
}
|
}
|
||||||
|
|
||||||
start() {
|
start() {
|
||||||
@ -1203,9 +1207,11 @@ export class SummonPhase extends PartyMemberPokemonPhase {
|
|||||||
|
|
||||||
pokemon.resetTurnData();
|
pokemon.resetTurnData();
|
||||||
|
|
||||||
this.scene.triggerPokemonFormChange(pokemon, SpeciesFormChangeActiveTrigger, true);
|
if (!this.loaded) {
|
||||||
|
this.scene.triggerPokemonFormChange(pokemon, SpeciesFormChangeActiveTrigger, true);
|
||||||
|
|
||||||
this.queuePostSummon();
|
this.queuePostSummon();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
queuePostSummon(): void {
|
queuePostSummon(): void {
|
||||||
|
Loading…
Reference in New Issue
Block a user