mirror of
https://github.com/smogon/pokemon-showdown.git
synced 2026-03-21 17:25:10 -05:00
Fix the interaction of Outrage and Protect.
Now it ends with confusion on the last turn of Outrage, and ends without confusion on any other turn. There's still a lot of disagreement on what exactly is supposed to happen, but I'm 90% sure this is right.
This commit is contained in:
parent
f3c48d0bd9
commit
fd998d4c39
11
movedex.js
11
movedex.js
|
|
@ -7226,8 +7226,15 @@ exports.BattleMovedex = {
|
|||
var lockedmove = source.getVolatile('lockedmove');
|
||||
if (lockedmove)
|
||||
{
|
||||
// Outrage counter is reset
|
||||
source.volatiles['lockedmove'].duration = lockedmove.durationCallback();
|
||||
// Outrage counter is removed
|
||||
if (source.volatiles['lockedmove'].duration === 1)
|
||||
{
|
||||
source.removeVolatile('lockedmove');
|
||||
}
|
||||
else
|
||||
{
|
||||
delete source.volatiles['lockedmove'];
|
||||
}
|
||||
}
|
||||
this.singleEvent('MoveFail', effect, null, target, source, effect);
|
||||
return null;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user