diff --git a/src/battle-text-parser.ts b/src/battle-text-parser.ts index b17bf62120..8df97c2ea5 100644 --- a/src/battle-text-parser.ts +++ b/src/battle-text-parser.ts @@ -183,6 +183,12 @@ class BattleTextParser { break; } + case '-heal': { + const id = BattleTextParser.effectId(kwArgs.from); + if (['dryskin', 'eartheater', 'voltabsorb', 'waterabsorb'].includes(id)) kwArgs.of = ''; + break; + } + case '-nothing': // OLD: |-nothing // NEW: |-activate||move:Splash @@ -930,7 +936,7 @@ class BattleTextParser { case '-heal': { let [, pokemon] = args; let template = this.template('heal', kwArgs.from, 'NODEFAULT'); - const line1 = this.maybeAbility(kwArgs.from, pokemon); + const line1 = this.maybeAbility(kwArgs.from, kwArgs.of || pokemon); if (template) { return line1 + template.replace('[POKEMON]', this.pokemon(pokemon)).replace('[SOURCE]', this.pokemon(kwArgs.of)).replace('[NICKNAME]', kwArgs.wisher); } diff --git a/src/battle.ts b/src/battle.ts index 2845a7d6d8..9f3985be78 100644 --- a/src/battle.ts +++ b/src/battle.ts @@ -1740,7 +1740,8 @@ export class Battle { if (kwArgs.from) { let effect = Dex.getEffect(kwArgs.from); - this.activateAbility(poke, effect); + let ofpoke = this.getPokemon(kwArgs.of); + this.activateAbility(ofpoke || poke, effect); if (effect.effectType === 'Item' && !CONSUMED.includes(poke.prevItemEffect)) { if (poke.prevItem !== effect.name) { poke.item = effect.name;