Reverted changes, someone else can sort

This commit is contained in:
EmoUsedHM01 2024-04-13 19:07:56 +01:00 committed by GitHub
parent 8369f5540c
commit 50f53516b8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -55,14 +55,7 @@ export function getStatusEffectActivationText(statusEffect: StatusEffect, pokemo
switch (statusEffect) { switch (statusEffect) {
case StatusEffect.POISON: case StatusEffect.POISON:
case StatusEffect.TOXIC: case StatusEffect.TOXIC:
// Placeholder, idk how to fix this, too new to typeScript, but it functions as normal anyway because of the pokemon && clause always returning the else value return ' is hurt\nby poison!';
if (pokemon && pokemon.getAbility().id === Abilities.POISON_HEAL) {
console.log("Poison Heal ability detected");
return ' had its\nHP restored!';
} else {
console.log("No Poison Heal ability detected");
return ' is hurt\nby poison!';
}
case StatusEffect.PARALYSIS: case StatusEffect.PARALYSIS:
return ' is paralyzed!\nIt can\'t move!'; return ' is paralyzed!\nIt can\'t move!';
case StatusEffect.SLEEP: case StatusEffect.SLEEP: