Fix Sleep Talk bugs
This commit is contained in:
parent
e07ba5680d
commit
d7ee958d29
|
@ -2929,7 +2929,7 @@ export class RandomMovesetMoveAttr extends OverrideMoveEffectAttr {
|
||||||
: moveTargets.targets.indexOf(target.getBattlerIndex()) > -1
|
: moveTargets.targets.indexOf(target.getBattlerIndex()) > -1
|
||||||
? [ target.getBattlerIndex() ]
|
? [ target.getBattlerIndex() ]
|
||||||
: [ moveTargets.targets[user.randSeedInt(moveTargets.targets.length)] ];
|
: [ moveTargets.targets[user.randSeedInt(moveTargets.targets.length)] ];
|
||||||
user.getMoveQueue().push({ move: move.moveId, targets: targets, ignorePP: this.enemyMoveset });
|
user.getMoveQueue().push({ move: move.moveId, targets: targets, ignorePP: true });
|
||||||
user.scene.unshiftPhase(new MovePhase(user.scene, user, targets, moveset[moveIndex], true));
|
user.scene.unshiftPhase(new MovePhase(user.scene, user, targets, moveset[moveIndex], true));
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -4117,7 +4117,8 @@ export function initMoves() {
|
||||||
new SelfStatusMove(Moves.SLEEP_TALK, Type.NORMAL, -1, 10, -1, 0, 2)
|
new SelfStatusMove(Moves.SLEEP_TALK, Type.NORMAL, -1, 10, -1, 0, 2)
|
||||||
.attr(BypassSleepAttr)
|
.attr(BypassSleepAttr)
|
||||||
.attr(RandomMovesetMoveAttr)
|
.attr(RandomMovesetMoveAttr)
|
||||||
.condition((user, target, move) => user.status?.effect === StatusEffect.SLEEP),
|
.condition((user, target, move) => user.status?.effect === StatusEffect.SLEEP)
|
||||||
|
.ignoresVirtual(),
|
||||||
new StatusMove(Moves.HEAL_BELL, Type.NORMAL, -1, 5, -1, 0, 2)
|
new StatusMove(Moves.HEAL_BELL, Type.NORMAL, -1, 5, -1, 0, 2)
|
||||||
.soundBased()
|
.soundBased()
|
||||||
.target(MoveTarget.USER_AND_ALLIES)
|
.target(MoveTarget.USER_AND_ALLIES)
|
||||||
|
|
Loading…
Reference in New Issue