lhearachel / plat-engine

MIT License
3 stars 2 forks source link

Justified #66

Open lhearachel opened 1 year ago

lhearachel commented 1 year ago

Documentation

https://bulbapedia.bulbagarden.net/wiki/Justified_(Ability)

When a Pokémon with Justified is hit by a Dark-type damaging move, its Attack is increased by one stage. This ability does not provide immunity or reduction to the damage, nor does it activate from a Dark-type move hitting its Substitute. Dark-type multi-strike moves (such as Beat Up) will activate Justified once per strike, increasing the Attack stat that many stages.

Relevant Code Points

Function 0x0225708C needs a new branch to account for Justified. It should also check for the type of the move (Dark) and the defender being being a Substitute. It should then invoke the stat-change script with the Attack Up code.