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

Prevent sameMoveTurns from incrementing when unable to use move #6167

Merged
merged 1 commit into from
Feb 2, 2025

Conversation

moostoet
Copy link

@moostoet moostoet commented Feb 2, 2025

The MOVEEND_SAME_MOVE_TURNS case did not take into account Pokemon being unable to use their move (sleep, flinch, etc.) when checking to increment the sameMoveTurns counter. This resulted in a disparity in damage when, e.g., an Amaura was flinched when selecting Echoed Voice. Selecting it again next turn would have the counter be higher than it should be. This is unintended behavior and as such, a bug; confirmed by testing it against Smogon's engine.

Description

Adds a hitmarker check for HITMARKER_UNABLE_TO_USE_MOVE in the MOVEEND_SAME_MOVE_TURNS case in Cmd_moveend.

Issue(s) that this PR fixes

#6165

Discord contact info

viridian.

@Bassoonian Bassoonian added category: battle-mechanic Pertains to battle mechanics bugfix Bugfixes labels Feb 2, 2025
@Bassoonian Bassoonian merged commit ddff2de into rh-hideout:master Feb 2, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix Bugfixes category: battle-mechanic Pertains to battle mechanics
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants