Fixed when roost removes flying type (#148)
* Initial push with roost fix * Roost fix * Added GROUNDED to Levitate * Cleaned up GROUNDED code
This commit is contained in:
1 parent
7bc147166e
commit
1f9834d1f6
6 files changed
+12
-8
No files matched your search
+1
-1
@@ -2222,7 +2222,7 @@ export function initAbilities() {
|
||||
.attr(UnswappableAbilityAbAttr)
|
||||
.ignorable(),
|
||||
new Ability(Abilities.LEVITATE, "Levitate", "By floating in the air, the Pokémon receives full immunity to all Ground-type moves.", 3)
|
||||
.attr(TypeImmunityAbAttr, Type.GROUND, (pokemon: Pokemon) => !pokemon.getTag(BattlerTagType.IGNORE_FLYING) && !pokemon.scene.arena.getTag(ArenaTagType.GRAVITY))
|
||||
.attr(TypeImmunityAbAttr, Type.GROUND, (pokemon: Pokemon) => !pokemon.getTag(BattlerTagType.IGNORE_FLYING) && !pokemon.scene.arena.getTag(ArenaTagType.GRAVITY) && !pokemon.getTag(BattlerTagType.GROUNDED))
|
||||
.ignorable(),
|
||||
new Ability(Abilities.EFFECT_SPORE, "Effect Spore", "Contact with the Pokémon may inflict poison, sleep, or paralysis on its attacker.", 3)
|
||||
.attr(PostDefendContactApplyStatusEffectAbAttr, 10, StatusEffect.POISON, StatusEffect.PARALYSIS, StatusEffect.SLEEP),
|
||||
|
||||
@@ -1094,6 +1094,8 @@ export function getBattlerTag(tagType: BattlerTagType, turnCount: integer, sourc
|
||||
return new BattlerTag(BattlerTagType.BYPASS_SLEEP, BattlerTagLapseType.TURN_END, turnCount, sourceMove);
|
||||
case BattlerTagType.IGNORE_FLYING:
|
||||
return new BattlerTag(tagType, BattlerTagLapseType.TURN_END, turnCount, sourceMove);
|
||||
case BattlerTagType.GROUNDED:
|
||||
return new BattlerTag(tagType, BattlerTagLapseType.TURN_END, turnCount - 1, sourceMove);
|
||||
case BattlerTagType.SALT_CURED:
|
||||
return new SaltCuredTag(sourceId);
|
||||
case BattlerTagType.NONE:
|
||||
@@ -1101,3 +1103,4 @@ export function getBattlerTag(tagType: BattlerTagType, turnCount: integer, sourc
|
||||
return new BattlerTag(tagType, BattlerTagLapseType.CUSTOM, turnCount, sourceMove, sourceId);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,5 +47,6 @@ export enum BattlerTagType {
|
||||
IGNORE_ACCURACY = "IGNORE_ACCURACY",
|
||||
BYPASS_SLEEP = "BYPASS_SLEEP",
|
||||
IGNORE_FLYING = "IGNORE_FLYING",
|
||||
GROUNDED = "GROUNDED",
|
||||
SALT_CURED = "SALT_CURED"
|
||||
}
|
||||
+2
-2
@@ -4415,7 +4415,7 @@ export function initMoves() {
|
||||
.attr(StatChangeAttr, BattleStat.SPATK, -2, true),
|
||||
new SelfStatusMove(Moves.ROOST, Type.FLYING, -1, 5, -1, 0, 4)
|
||||
.attr(HealAttr, 0.5)
|
||||
.attr(AddBattlerTagAttr, BattlerTagType.IGNORE_FLYING, true, false, 1)
|
||||
.attr(AddBattlerTagAttr, BattlerTagType.GROUNDED, true, false, 1)
|
||||
.triageMove(),
|
||||
new StatusMove(Moves.GRAVITY, Type.PSYCHIC, -1, 5, -1, 0, 4)
|
||||
.attr(AddArenaTagAttr, ArenaTagType.GRAVITY, 5)
|
||||
@@ -6043,4 +6043,4 @@ export function initMoves() {
|
||||
new AttackMove(Moves.MALIGNANT_CHAIN, Type.POISON, MoveCategory.SPECIAL, 100, 100, 5, 50, 0, 9)
|
||||
.attr(StatusEffectAttr, StatusEffect.TOXIC)
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user