Fix burn damage change affecting poison

This commit is contained in:
Flashfyre 2024-03-27 11:42:06 -04:00
parent c8ac42f267
commit f79337b475

View File

@ -2635,12 +2635,14 @@ export class PostTurnStatusEffectPhase extends PokemonPhase {
let damage: integer = 0; let damage: integer = 0;
switch (pokemon.status.effect) { switch (pokemon.status.effect) {
case StatusEffect.POISON: case StatusEffect.POISON:
case StatusEffect.BURN: damage = Math.max(pokemon.getMaxHp() >> 3, 1);
damage = Math.max(pokemon.getMaxHp() >> 4, 1);
break; break;
case StatusEffect.TOXIC: case StatusEffect.TOXIC:
damage = Math.max(Math.floor((pokemon.getMaxHp() / 16) * pokemon.status.turnCount), 1); damage = Math.max(Math.floor((pokemon.getMaxHp() / 16) * pokemon.status.turnCount), 1);
break; break;
case StatusEffect.BURN:
damage = Math.max(pokemon.getMaxHp() >> 4, 1);
break;
} }
if (damage) { if (damage) {
this.scene.damageNumberHandler.add(this.getPokemon(), pokemon.damage(damage)); this.scene.damageNumberHandler.add(this.getPokemon(), pokemon.damage(damage));