AI and other Gen 8 Effects (#123)

* Added Rattled being triggered by Intimidate in Gen 8
* Added Rapid Spin speed boost effect
* Added basic AI for Gen 8
* Tweaked Leppa berry's effect
* Added Ability Patch's exemption for Zygarde
* Added Curse's Gen 8 targeting change
* Added Teleport's Gen 8 effect
* Added check for Choice items in Instruct and Dancer
* Added Quash's Gen 8 change to the order that multiple Quashed Pokémon move in

Co-authored-by: Maruno17 <serialcolour@hotmail.com>
This commit is contained in:
Golisopod-User
2021-08-03 03:26:55 +05:30
committed by GitHub
parent ec84d581ad
commit c6da16409e
16 changed files with 543 additions and 77 deletions

View File

@@ -272,7 +272,7 @@ ItemHandlers::UseOnPokemon.add(:ABILITYPATCH, proc { |item, pkmn, scene|
abils = pkmn.getAbilityList
new_ability_id = nil
abils.each { |a| new_ability_id = a[0] if a[1] == 2 }
if !new_ability_id || pkmn.hasHiddenAbility?
if !new_ability_id || pkmn.hasHiddenAbility? || pkmn.isSpecies?(:ZYGARDE)
scene.pbDisplay(_INTL("It won't have any effect."))
next false
end