Show the move affected by Grudge as having 0 PP (#787)

This commit is contained in:
urkerab
2016-10-21 02:15:32 +01:00
committed by Guangcong Luo
parent 638c117db0
commit 660f1d24c4
2 changed files with 2 additions and 1 deletions

View File

@@ -5116,7 +5116,7 @@ var Battle = (function () {
break;
case 'grudge':
actions += "" + poke.getName() + "'s " + Tools.escapeHTML(args[3]) + " lost all of its PP due to the grudge!";
poke.markMove(args[3], 64);
poke.markMove(args[3], Infinity);
break;
case 'quickguard':
poke.addTurnstatus('quickguard');

View File

@@ -732,6 +732,7 @@ var BattleTooltips = (function () {
}
maxpp = Math.floor(maxpp * 8 / 5);
}
if (ppUsed === Infinity) return move.name + ' <small>(0/' + maxpp + ')</small>';
if (!ppUsed) return move.name + (showKnown ? ' <small>(revealed)</small>' : '');
return move.name + ' <small>(' + (maxpp - ppUsed) + '/' + maxpp + ')</small>';
};