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

[Move] Rage Fist Implementation #5165

Open
wants to merge 17 commits into
base: beta
Choose a base branch
from

Conversation

geeilhan
Copy link
Contributor

@geeilhan geeilhan commented Jan 22, 2025

Continuation of this Rage Fist PR
(#3503)

What are the changes the user will see?

Confusion self inflicted hits does not count to the increased power of rage fist

What are the changes from a developer perspective?

Added a confHitCount to pokemon.battleData which only counts self inflicted hits due to confusion. this number gets subtracted from hitCount in order to get the correct hitCount value for rage fist

Screenshots/Videos

For reference look at the videos from this PR

How to test the changes?

Spam Splash until you get confused then use Rage Fist and pray for a self hit

const overrides = {
  OPP_SPECIES_OVERRIDE: Species.MAGIKARP,
  OPP_LEVEL_OVERRIDE: 1,
  OPP_MOVESET_OVERRIDE: [ Moves.CONFUSE_RAY, Moves.TACKLE ],
  MOVESET_OVERRIDE: [ Moves.RAGE_FIST, Moves.SPLASH ],
  STARTING_LEVEL_OVERRIDE: 100,
  STARTING_WAVE_OVERRIDE: 1,
} satisfies Partial<InstanceType<typeof DefaultOverrides>>;

Checklist

  • I'm using beta as my base branch
  • There is no overlap with another PR?
  • The PR is self-contained and cannot be split into smaller PRs?
  • Have I provided a clear explanation of the changes?
  • Have I tested the changes manually?
  • Are all unit tests still passing? (npm run test)
    • Have I created new automated tests (npm run create-test) or updated existing tests related to the PR's changes?
  • Have I provided screenshots/videos of the changes (if applicable)?
    • Have I made sure that any UI change works for both UI themes (default and legacy)?

@geeilhan geeilhan requested a review from a team as a code owner January 22, 2025 01:45
@Madmadness65 Madmadness65 added the Move Affects a move label Jan 26, 2025
Copy link
Member

@SirzBenjie SirzBenjie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

code looks good, but for cases like these I like to see automated tests. I can write, if necessary :)

As in, can we get an automated test specifically for ensuring confusion hits don't increase damage? I think you can mock the confusion check to force the mon to hit itself.

@geeilhan
Copy link
Contributor Author

code looks good, but for cases like these I like to see automated tests. I can write, if necessary :)

As in, can we get an automated test specifically for ensuring confusion hits don't increase damage? I think you can mock the confusion check to force the mon to hit itself.

That would be nice. I couldn't write tests for the confusion case because I didn't know how to mock it.

@SirzBenjie
Copy link
Member

code looks good, but for cases like these I like to see automated tests. I can write, if necessary :)
As in, can we get an automated test specifically for ensuring confusion hits don't increase damage? I think you can mock the confusion check to force the mon to hit itself.

That would be nice. I couldn't write tests for the confusion case because I didn't know how to mock it.

Okay, I'll add it 🫡

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Move Affects a move
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants