Merge 28cdc10ff3 into 7a1895242c
commit
447d0aeb2d
|
|
@ -1075,6 +1075,24 @@ export class CursedTag extends BattlerTag {
|
|||
}
|
||||
}
|
||||
|
||||
export class HealBlockTag extends BattlerTag {
|
||||
constructor(turnCount : integer, sourceMove : Moves) {
|
||||
super(BattlerTagType.HEAL_BLOCKED, BattlerTagLapseType.TURN_END, turnCount, sourceMove);
|
||||
}
|
||||
|
||||
onAdd(pokemon: Pokemon) {
|
||||
super.onAdd(pokemon);
|
||||
|
||||
pokemon.scene.queueMessage(getPokemonMessage(pokemon, ' was prevented from healing!'));
|
||||
}
|
||||
|
||||
onRemove(pokemon: Pokemon): void {
|
||||
super.onRemove(pokemon);
|
||||
|
||||
pokemon.scene.queueMessage(getPokemonMessage(pokemon, '\'s ' + super.getMoveName() + ' wore off!'));
|
||||
}
|
||||
}
|
||||
|
||||
export function getBattlerTag(tagType: BattlerTagType, turnCount: integer, sourceMove: Moves, sourceId: integer): BattlerTag {
|
||||
switch (tagType) {
|
||||
case BattlerTagType.RECHARGING:
|
||||
|
|
@ -1178,6 +1196,8 @@ export function getBattlerTag(tagType: BattlerTagType, turnCount: integer, sourc
|
|||
return new CursedTag(sourceId);
|
||||
case BattlerTagType.CHARGED:
|
||||
return new TypeBoostTag(tagType, sourceMove, Type.ELECTRIC, 2, true);
|
||||
case BattlerTagType.HEAL_BLOCKED:
|
||||
return new HealBlockTag(turnCount, sourceMove);
|
||||
case BattlerTagType.NONE:
|
||||
default:
|
||||
return new BattlerTag(tagType, BattlerTagLapseType.CUSTOM, turnCount, sourceMove, sourceId);
|
||||
|
|
|
|||
|
|
@ -52,5 +52,6 @@ export enum BattlerTagType {
|
|||
SALT_CURED = "SALT_CURED",
|
||||
CURSED = "CURSED",
|
||||
CHARGED = "CHARGED",
|
||||
HEAL_BLOCKED = "HEAL_BLOCKED",
|
||||
GROUNDED = "GROUNDED"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4762,7 +4762,8 @@ export function initMoves() {
|
|||
.unimplemented(),
|
||||
new StatusMove(Moves.HEAL_BLOCK, Type.PSYCHIC, 100, 15, -1, 0, 4)
|
||||
.target(MoveTarget.ALL_NEAR_ENEMIES)
|
||||
.unimplemented(),
|
||||
.attr(AddBattlerTagAttr, BattlerTagType.HEAL_BLOCKED, false, true, 5)
|
||||
.partial(),
|
||||
new AttackMove(Moves.WRING_OUT, Type.NORMAL, MoveCategory.SPECIAL, -1, 100, 5, -1, 0, 4)
|
||||
.attr(OpponentHighHpPowerAttr)
|
||||
.makesContact(),
|
||||
|
|
@ -6359,6 +6360,7 @@ export function initMoves() {
|
|||
.attr(NoEffectAttr, crashDamageFunc),
|
||||
new AttackMove(Moves.PSYCHIC_NOISE, Type.PSYCHIC, MoveCategory.SPECIAL, 75, 100, 10, -1, 0, 9)
|
||||
.soundBased()
|
||||
.attr(AddBattlerTagAttr, BattlerTagType.HEAL_BLOCKED, false, true, 2)
|
||||
.partial(),
|
||||
new AttackMove(Moves.UPPER_HAND, Type.FIGHTING, MoveCategory.PHYSICAL, 65, 100, 15, -1, 3, 9)
|
||||
.partial(),
|
||||
|
|
|
|||
|
|
@ -4269,6 +4269,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 30, Moves.ANCIENT_POWER ],
|
||||
[ 40, Moves.LIFE_DEW ],
|
||||
[ 50, Moves.LEECH_SEED ],
|
||||
[ 55, Moves.HEAL_BLOCK ],
|
||||
[ 60, Moves.RECOVER ],
|
||||
[ 70, Moves.FUTURE_SIGHT ],
|
||||
[ 80, Moves.HEALING_WISH ],
|
||||
|
|
@ -4967,6 +4968,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 23, Moves.ABSORB ],
|
||||
[ 29, Moves.SHADOW_SNEAK ],
|
||||
[ 36, Moves.FURY_SWIPES ],
|
||||
[ 41, Moves.HEAL_BLOCK ],
|
||||
[ 43, Moves.MIND_READER ],
|
||||
[ 50, Moves.SHADOW_BALL ],
|
||||
[ 57, Moves.SPITE ],
|
||||
|
|
@ -5787,6 +5789,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 20, Moves.PSYSHOCK ],
|
||||
[ 25, Moves.COSMIC_POWER ],
|
||||
[ 30, Moves.PSYCHIC ],
|
||||
[ 33, Moves.HEAL_BLOCK ],
|
||||
[ 35, Moves.STONE_EDGE ],
|
||||
[ 40, Moves.FUTURE_SIGHT ],
|
||||
[ 45, Moves.MAGIC_ROOM ],
|
||||
|
|
@ -5805,6 +5808,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 20, Moves.ZEN_HEADBUTT ],
|
||||
[ 25, Moves.COSMIC_POWER ],
|
||||
[ 30, Moves.PSYCHIC ],
|
||||
[ 33, Moves.HEAL_BLOCK ],
|
||||
[ 35, Moves.STONE_EDGE ],
|
||||
[ 40, Moves.SOLAR_BEAM ],
|
||||
[ 45, Moves.WONDER_ROOM ],
|
||||
|
|
@ -5881,6 +5885,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 3, Moves.RAPID_SPIN ],
|
||||
[ 6, Moves.CONFUSION ],
|
||||
[ 9, Moves.ROCK_TOMB ],
|
||||
[ 10, Moves.HEAL_BLOCK ],
|
||||
[ 12, Moves.POWER_TRICK ],
|
||||
[ 15, Moves.PSYBEAM ],
|
||||
[ 18, Moves.ANCIENT_POWER ],
|
||||
|
|
@ -5902,6 +5907,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 1, Moves.MUD_SLAP ],
|
||||
[ 1, Moves.RAPID_SPIN ],
|
||||
[ 9, Moves.ROCK_TOMB ],
|
||||
[ 10, Moves.HEAL_BLOCK ],
|
||||
[ 12, Moves.POWER_TRICK ],
|
||||
[ 15, Moves.PSYBEAM ],
|
||||
[ 18, Moves.ANCIENT_POWER ],
|
||||
|
|
@ -6497,6 +6503,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[Species.LATIOS]: [
|
||||
[ 1, Moves.DRAGON_DANCE ],
|
||||
[ 1, Moves.STORED_POWER ],
|
||||
[ 1, Moves.HEAL_BLOCK ],
|
||||
[ 5, Moves.HELPING_HAND ],
|
||||
[ 10, Moves.RECOVER ],
|
||||
[ 15, Moves.CONFUSION ],
|
||||
|
|
@ -7355,6 +7362,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 36, Moves.IRON_DEFENSE ],
|
||||
[ 40, Moves.METAL_SOUND ],
|
||||
[ 44, Moves.FUTURE_SIGHT ],
|
||||
[ 45, Moves.HEAL_BLOCK ],
|
||||
],
|
||||
[Species.BRONZONG]: [
|
||||
[ 0, Moves.BLOCK ],
|
||||
|
|
@ -7373,6 +7381,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 38, Moves.IRON_DEFENSE ],
|
||||
[ 44, Moves.METAL_SOUND ],
|
||||
[ 50, Moves.FUTURE_SIGHT ],
|
||||
[ 52, Moves.HEAL_BLOCK ],
|
||||
[ 56, Moves.RAIN_DANCE ],
|
||||
],
|
||||
[Species.BONSLY]: [
|
||||
|
|
@ -9709,6 +9718,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 24, Moves.HYPNOSIS ],
|
||||
[ 28, Moves.FAKE_TEARS ],
|
||||
[ 33, Moves.PSYCH_UP ],
|
||||
[ 33, Moves.HEAL_BLOCK ],
|
||||
[ 36, Moves.PSYCHIC ],
|
||||
[ 40, Moves.FLATTER ],
|
||||
[ 44, Moves.FUTURE_SIGHT ],
|
||||
|
|
@ -9724,6 +9734,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 20, Moves.PSYSHOCK ],
|
||||
[ 24, Moves.HYPNOSIS ],
|
||||
[ 28, Moves.FAKE_TEARS ],
|
||||
[ 34, Moves.HEAL_BLOCK ],
|
||||
[ 35, Moves.PSYCH_UP ],
|
||||
[ 46, Moves.FLATTER ],
|
||||
[ 52, Moves.FUTURE_SIGHT ],
|
||||
|
|
@ -9739,6 +9750,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 20, Moves.PSYSHOCK ],
|
||||
[ 24, Moves.HYPNOSIS ],
|
||||
[ 28, Moves.FAKE_TEARS ],
|
||||
[ 34, Moves.HEAL_BLOCK ],
|
||||
[ 35, Moves.PSYCH_UP ],
|
||||
[ 40, Moves.PSYCHIC ],
|
||||
[ 48, Moves.FLATTER ],
|
||||
|
|
@ -9760,6 +9772,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 36, Moves.PSYCHIC ],
|
||||
[ 40, Moves.SKILL_SWAP ],
|
||||
[ 44, Moves.FUTURE_SIGHT ],
|
||||
[ 46, Moves.HEAL_BLOCK ],
|
||||
[ 48, Moves.WONDER_ROOM ],
|
||||
],
|
||||
[Species.DUOSION]: [
|
||||
|
|
@ -9776,6 +9789,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 35, Moves.PAIN_SPLIT ],
|
||||
[ 40, Moves.PSYCHIC ],
|
||||
[ 46, Moves.SKILL_SWAP ],
|
||||
[ 50, Moves.HEAL_BLOCK ],
|
||||
[ 52, Moves.FUTURE_SIGHT ],
|
||||
[ 58, Moves.WONDER_ROOM ],
|
||||
],
|
||||
|
|
@ -9794,6 +9808,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 35, Moves.PAIN_SPLIT ],
|
||||
[ 40, Moves.PSYCHIC ],
|
||||
[ 48, Moves.SKILL_SWAP ],
|
||||
[ 54, Moves.HEAL_BLOCK ],
|
||||
[ 56, Moves.FUTURE_SIGHT ],
|
||||
[ 64, Moves.WONDER_ROOM ],
|
||||
],
|
||||
|
|
@ -10198,6 +10213,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 1, Moves.GROWL ],
|
||||
[ 1, Moves.CONFUSION ],
|
||||
[ 6, Moves.IMPRISON ],
|
||||
[ 8, Moves.HEAL_BLOCK ],
|
||||
[ 12, Moves.TELEPORT ],
|
||||
[ 18, Moves.PSYBEAM ],
|
||||
[ 24, Moves.GUARD_SPLIT ],
|
||||
|
|
@ -10215,6 +10231,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 1, Moves.TELEPORT ],
|
||||
[ 1, Moves.IMPRISON ],
|
||||
[ 1, Moves.PSYCHIC_TERRAIN ],
|
||||
[ 8, Moves.HEAL_BLOCK ],
|
||||
[ 18, Moves.PSYBEAM ],
|
||||
[ 24, Moves.GUARD_SPLIT ],
|
||||
[ 24, Moves.POWER_SPLIT ],
|
||||
|
|
@ -10872,6 +10889,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 15, Moves.BITE ],
|
||||
[ 20, Moves.SHOCK_WAVE ],
|
||||
[ 25, Moves.AGILITY ],
|
||||
[ 25, Moves.HEAL_BLOCK ],
|
||||
[ 30, Moves.CHARGE ],
|
||||
[ 35, Moves.VOLT_SWITCH ],
|
||||
[ 40, Moves.CRUNCH ],
|
||||
|
|
@ -11960,6 +11978,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 40, Moves.PLAY_ROUGH ],
|
||||
[ 44, Moves.MAGIC_ROOM ],
|
||||
[ 48, Moves.FOUL_PLAY ],
|
||||
[ 50, Moves.HEAL_BLOCK ],
|
||||
[ 52, Moves.LAST_RESORT ],
|
||||
],
|
||||
[Species.PHANTUMP]: [
|
||||
|
|
@ -13033,6 +13052,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 45, Moves.IRON_HEAD ],
|
||||
[ 50, Moves.TAKE_DOWN ],
|
||||
[ 55, Moves.DOUBLE_EDGE ],
|
||||
[ 85, Moves.HEAL_BLOCK ],
|
||||
],
|
||||
[Species.SILVALLY]: [
|
||||
[ 0, Moves.MULTI_ATTACK ],
|
||||
|
|
@ -13041,6 +13061,7 @@ export const pokemonSpeciesLevelMoves: PokemonSpeciesLevelMoves = {
|
|||
[ 1, Moves.EXPLOSION ],
|
||||
[ 1, Moves.SCARY_FACE ],
|
||||
[ 1, Moves.IMPRISON ],
|
||||
[ 1, Moves.HEAL_BLOCK ],
|
||||
[ 1, Moves.POISON_FANG ],
|
||||
[ 1, Moves.AERIAL_ACE ],
|
||||
[ 1, Moves.THUNDER_FANG ],
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ import { Biome } from "./data/enums/biome";
|
|||
import { ModifierTier } from "./modifier/modifier-tier";
|
||||
import { FusePokemonModifierType, ModifierPoolType, ModifierType, ModifierTypeFunc, ModifierTypeOption, PokemonModifierType, PokemonMoveModifierType, RememberMoveModifierType, TmModifierType, getDailyRunStarterModifiers, getEnemyBuffModifierForWave, getModifierType, getPlayerModifierTypeOptions, getPlayerShopModifierTypeOptionsForWave, modifierTypes, regenerateModifierPoolThresholds } from "./modifier/modifier-type";
|
||||
import SoundFade from "phaser3-rex-plugins/plugins/soundfade";
|
||||
import { BattlerTagLapseType, EncoreTag, HideSpriteTag as HiddenTag, ProtectedTag, TrappedTag } from "./data/battler-tags";
|
||||
import { BattlerTagLapseType, EncoreTag, HealBlockTag, HideSpriteTag as HiddenTag, ProtectedTag, TrappedTag } from "./data/battler-tags";
|
||||
import { BattlerTagType } from "./data/enums/battler-tag-type";
|
||||
import { getPokemonMessage } from "./messages";
|
||||
import { Starter } from "./ui/starter-select-ui-handler";
|
||||
|
|
@ -3867,6 +3867,12 @@ export class PokemonHealPhase extends CommonAnimPhase {
|
|||
return;
|
||||
}
|
||||
|
||||
if (pokemon.getTag(HealBlockTag)) {
|
||||
this.scene.queueMessage(getPokemonMessage(pokemon, ' was prevented from healing!'));
|
||||
super.end();
|
||||
return;
|
||||
}
|
||||
|
||||
const fullHp = pokemon.getHpRatio() >= 1;
|
||||
|
||||
const hasMessage = !!this.message;
|
||||
|
|
|
|||
Loading…
Reference in New Issue