Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Self-hits in confusion isn't handled correctly under GSC #1618

Open
FredrIQ opened this issue Feb 12, 2017 · 0 comments
Open

Self-hits in confusion isn't handled correctly under GSC #1618

FredrIQ opened this issue Feb 12, 2017 · 0 comments

Comments

@FredrIQ
Copy link

FredrIQ commented Feb 12, 2017

This isn't reflected in Pokémon Online.

Pokémon Online relevant code: BattleBase::inflictConfusedDamage

GSC relevant code: in pret/pokecrystal, see the .confused label in CheckPlayerTurn/CheckEnemyTurn, it runs HitSelfInConfusion (sets appropriate registers to attack/defense after Reflect/level/40 base power), then runs BattleCommand_DamageCalc which checks type boosting items according to the move struct (e.g. not something self-confusion touches) which potentially procs type-boosting items, then after animation related code, sets c to 1 (to ignore Substitute) and runs PlayerHurtItself/EnemyHurtItself (to deal the damage). This means that PO does the following wrong:

  • It procs damage rolls
  • It doesn't proc type boosting items if the move you selected would have been affected by it
  • It ignores Reflect
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant