mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-08-24 08:19:33 +02:00
fix undefined property error
This commit is contained in:
parent
01f3b00bc4
commit
8c1adbc2f0
@ -1538,9 +1538,10 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
|
|||||||
* @returns The type damage multiplier, indicating the effectiveness of the move
|
* @returns The type damage multiplier, indicating the effectiveness of the move
|
||||||
*/
|
*/
|
||||||
getMoveEffectiveness(source: Pokemon, move: Move, ignoreAbility: boolean = false, simulated: boolean = true, cancelled?: Utils.BooleanHolder): TypeDamageMultiplier {
|
getMoveEffectiveness(source: Pokemon, move: Move, ignoreAbility: boolean = false, simulated: boolean = true, cancelled?: Utils.BooleanHolder): TypeDamageMultiplier {
|
||||||
if (this.turnData.moveEffectiveness !== null) {
|
if (!Utils.isNullOrUndefined(this.turnData.moveEffectiveness)) {
|
||||||
return this.turnData.moveEffectiveness;
|
return this.turnData.moveEffectiveness;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (move.hasAttr(TypelessAttr)) {
|
if (move.hasAttr(TypelessAttr)) {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user