Fix Beat Up using wrong form stat (#10986)

* Fix Beat Up using wrong form stat

* Fix Beat Up in older gens
This commit is contained in:
André Bastos Dias 2025-05-01 06:41:02 +01:00 committed by GitHub
parent 4d227e26dc
commit 9fac6d66cc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 7 additions and 7 deletions

View File

@ -47,12 +47,12 @@ export const Moves: import('../../../sim/dex-moves').ModdedMoveDataTable = {
// https://www.smogon.com/forums/posts/8992145/
// this.add('-activate', pokemon, 'move: Beat Up', '[of] ' + move.allies![0].name);
this.event.modifier = 1;
return move.allies!.shift()!.species.baseStats.atk;
return this.dex.species.get(move.allies!.shift()!.set.species).baseStats.atk;
},
onFoeModifySpDPriority: -101,
onFoeModifySpD(def, pokemon) {
this.event.modifier = 1;
return pokemon.species.baseStats.def;
return this.dex.species.get(pokemon.set.species).baseStats.def;
},
},
},

View File

@ -95,12 +95,12 @@ export const Moves: import('../../../sim/dex-moves').ModdedMoveDataTable = {
// https://www.smogon.com/forums/posts/8992145/
// this.add('-activate', pokemon, 'move: Beat Up', '[of] ' + move.allies![0].name);
this.event.modifier = 1;
return move.allies!.shift()!.species.baseStats.atk;
return this.dex.species.get(move.allies!.shift()!.set.species).baseStats.atk;
},
onFoeModifyDefPriority: -101,
onFoeModifyDef(def, pokemon) {
this.event.modifier = 1;
return pokemon.species.baseStats.def;
return this.dex.species.get(pokemon.set.species).baseStats.def;
},
},
},

View File

@ -1194,9 +1194,9 @@ export const Moves: import('../sim/dex-moves').MoveDataTable = {
accuracy: 100,
basePower: 0,
basePowerCallback(pokemon, target, move) {
const currentSpecies = move.allies!.shift()!.species;
const bp = 5 + Math.floor(currentSpecies.baseStats.atk / 10);
this.debug(`BP for ${currentSpecies.name} hit: ${bp}`);
const setSpecies = this.dex.species.get(move.allies!.shift()!.set.species);
const bp = 5 + Math.floor(setSpecies.baseStats.atk / 10);
this.debug(`BP for ${setSpecies.name} hit: ${bp}`);
return bp;
},
category: "Physical",