Fix strong winds effect not working on moves
parent
8b382dd42e
commit
a0e2427974
|
@ -1096,6 +1096,9 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container {
|
||||||
typeMultiplier.value = 1;
|
typeMultiplier.value = 1;
|
||||||
if (this.getTypes(true, true).find(t => move.isTypeImmune(t)))
|
if (this.getTypes(true, true).find(t => move.isTypeImmune(t)))
|
||||||
typeMultiplier.value = 0;
|
typeMultiplier.value = 0;
|
||||||
|
// Handle strong winds lowering effectiveness of types super effective against pure flying
|
||||||
|
if (this.scene.arena.weather?.weatherType === WeatherType.STRONG_WINDS && !this.scene.arena.weather.isEffectSuppressed(this.scene) && typeMultiplier.value >= 2 && this.isOfType(Type.FLYING) && getTypeDamageMultiplier(move.type, Type.FLYING) === 2)
|
||||||
|
typeMultiplier.value /= 2;
|
||||||
|
|
||||||
switch (moveCategory) {
|
switch (moveCategory) {
|
||||||
case MoveCategory.PHYSICAL:
|
case MoveCategory.PHYSICAL:
|
||||||
|
|
Loading…
Reference in New Issue