mirror of
https://github.com/smogon/pokemon-showdown.git
synced 2026-09-07 08:45:32 -05:00
Merge pull request #894 from Slayer95/assurance
Pass target location to ´beforeTurnCallback´
This commit is contained in:
@@ -3115,7 +3115,7 @@ var Battle = (function () {
|
||||
}
|
||||
if (decision.choice === 'move') {
|
||||
if (this.getMove(decision.move).beforeTurnCallback) {
|
||||
this.addQueue({choice: 'beforeTurnMove', pokemon: decision.pokemon, move: decision.move}, true);
|
||||
this.addQueue({choice: 'beforeTurnMove', pokemon: decision.pokemon, move: decision.move, targetLoc: decision.targetLoc}, true);
|
||||
}
|
||||
} else if (decision.choice === 'switch') {
|
||||
if (decision.pokemon.switchFlag && decision.pokemon.switchFlag !== true) {
|
||||
|
||||
@@ -275,7 +275,7 @@ exports.BattleScripts = {
|
||||
}
|
||||
if (decision.choice === 'move') {
|
||||
if (this.getMove(decision.move).beforeTurnCallback) {
|
||||
this.addQueue({choice: 'beforeTurnMove', pokemon: decision.pokemon, move: decision.move}, true);
|
||||
this.addQueue({choice: 'beforeTurnMove', pokemon: decision.pokemon, move: decision.move, targetLoc: decision.targetLoc}, true);
|
||||
}
|
||||
} else if (decision.choice === 'switch') {
|
||||
if (decision.pokemon.switchFlag && decision.pokemon.switchFlag !== true) {
|
||||
|
||||
Reference in New Issue
Block a user