mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-07-17 05:42:18 +02:00
Refactored the Lum Berry case
This commit is contained in:
parent
2382579ffb
commit
b87b4a7fc3
@ -91,13 +91,10 @@ export function getBerryEffectFunc(berryType: BerryType): BerryEffectFunc {
|
|||||||
return (pokemon: Pokemon) => {
|
return (pokemon: Pokemon) => {
|
||||||
if (pokemon.battleData)
|
if (pokemon.battleData)
|
||||||
pokemon.battleData.berriesEaten.push(berryType);
|
pokemon.battleData.berriesEaten.push(berryType);
|
||||||
if (pokemon.status) {
|
if (pokemon.status)
|
||||||
pokemon.scene.queueMessage(getPokemonMessage(pokemon, getStatusEffectHealText(pokemon.status.effect)));
|
pokemon.scene.queueMessage(getPokemonMessage(pokemon, getStatusEffectHealText(pokemon.status.effect)));
|
||||||
pokemon.resetStatus();
|
pokemon.resetStatus(true, true)
|
||||||
pokemon.updateInfo();
|
pokemon.updateInfo();
|
||||||
}
|
|
||||||
if (pokemon.getTag(BattlerTagType.CONFUSED))
|
|
||||||
pokemon.lapseTag(BattlerTagType.CONFUSED);
|
|
||||||
};
|
};
|
||||||
case BerryType.LIECHI:
|
case BerryType.LIECHI:
|
||||||
case BerryType.GANLON:
|
case BerryType.GANLON:
|
||||||
|
Loading…
Reference in New Issue
Block a user