Added BattlePokemon#isGrounded to check for the grounded-ness of a
Pokemon. Also BattlePokemon#isSemiInvulnerable for whether a Pokemon is
in the first turn of a two-turn move that makes them semi-invulnerable.
Fixed Terrain bugs involving Pokemon in a semi-invulnerable state.
Changed OHKO move check to use BattlePokemon#isSemiInvulnerable, fixing a
graphical bug that would display an immunity message when a Pokemon
attempted an OHKO move on a higher-leveled Pokemon that was being held by
the effect of Sky Drop.
Fixed Misty Terrain bug that was causing Rest and the effect of Yawn to
put Pokemon to sleep.
Fixed Misty Terrain bug that was causing Yawn to fail.
Fixed Electric Terrain bug that was causing Yawn to succeed.
Instead of having a hardcode in scripts.js that people needed to
reference, it seemed more intuitive to take advantage of the Damage
event instead, and have Rock Head negate damage within the event.
Fixed a bug in Gen-NEXT Rock Head exhibiting the same behavior that
was causing the original Rock Head + Mummy glitch.
BattlePokemon#ignoringItem and BattlePokemon#ignoringAbility are
hardcodedto return true for any situation where pokemon.ignore['Item']
or pokemon.ignore['Ability'] respectively would have been true.
- Fissure can hit Dig and Whirlwind can hit Fly
- Use BasePower instead of ModifyDamage for doubled power moves
- Also correct current-gen Fly to modify damage instead of base power
The intention for this event is to remove the move disabling code away
from ModifyPokemon and to an event that can be run a fewer number of
times. Since the disabledMoves index is used to gray-out moves that cannot
be used, and not for any other purpose, there is no need for the related
code to be run at the ModifyPokemon timing, instead working better as a
once per turn event.
This was implemented exactly the wrong way and showed fail messages
in a lot of situations they shouldn't show up, such as when
Close Combat's Def/SpD drops didn't happen.
This reverts commit 1edc40f936.
The relation is hard-coded because no other move changes based on the
user's type the way Curse does, and the alternative would require
refactoring some things with the event ordering.
- No longer leaks information that the opponent has no moves left
whether or not they actually attack with Struggle
- Now shows the correct recoil message
- Gen 3 and earlier now have the correct accuracy
While move.affectedByImmunities was always a Boolean value to denote if
the move was affected by immunities, move.ignoreImmunity can be a Boolean
value if it ignores or is affected by all type immunities, but also can
act as an object such that !!move.ignoreImmunity[type] means it ignores
immunities of that type.
Almost everything learns Hidden Power. Fire and Ice are the most common types used competitively so choose to show them only in the Teambuilder as "usable".
Moves such as Teeter Dance and Stockpile are just awful on everything,
Searing shot is not viable on the only Pokemon that gets it sadly,
Infestation is not good on anything simply and should get close to
zero usage. Retailate is a wasted moveslot on everything. @xfix said
that me doing this was fine :)
Fixes the bug introduced in 555bae44d1 in which Focus Punch is stopped by hitting a Substitute, totally breaking the somewhat common SubPunch tactic.
It also now takes into account that damage should be higher than 0 if existing.