Skip to content

Commit

Permalink
Tooltips: Support Ogerpon mask boost (smogon#2151)
Browse files Browse the repository at this point in the history
  • Loading branch information
Karthik99999 authored and MathyFurret committed Mar 25, 2024
1 parent f627c80 commit 73b857c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/battle-text-parser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -966,7 +966,7 @@ class BattleTextParser {
return line1 + template.replace('[POKEMON]', this.pokemon(pokemon)).replace('[STAT]', BattleTextParser.stat(stat)).replace('[ITEM]', this.effect(kwArgs.from));
}
const template = this.template(templateId, kwArgs.from);
return line1 + template.replace('[POKEMON]', this.pokemon(pokemon)).replace('[STAT]', BattleTextParser.stat(stat));
return line1 + template.replace(/\[POKEMON\]/g, this.pokemon(pokemon)).replace('[STAT]', BattleTextParser.stat(stat));
}

case '-setboost': {
Expand Down
6 changes: 6 additions & 0 deletions src/battle-tooltips.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2114,6 +2114,12 @@ class BattleTooltips {
value.itemModify(1.2);
return value;
}
if ((speciesName.startsWith('Ogerpon-Wellspring') && itemName === 'Wellspring Mask') ||
(speciesName.startsWith('Ogerpon-Hearthflame') && itemName === 'Hearthflame Mask') ||
(speciesName.startsWith('Ogerpon-Cornerstone') && itemName === 'Cornerstone Mask')) {
value.itemModify(1.2);
return value;
}

// Gems
if (BattleTooltips.noGemMoves.includes(moveName)) return value;
Expand Down

0 comments on commit 73b857c

Please sign in to comment.