-
Notifications
You must be signed in to change notification settings - Fork 367
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
Toxic fix #596
Toxic fix #596
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello, these changes are appreciated but a few requests:
- Remove the
.vs/
files - Please write tests for this. EOT code is hard to work with so it would be great for sanity's sake
Also, can you elaborate on what 'End of turn damage is now considered on the first turn' means?
Thanks, your explanation clears it up.
Don't worry, get to it whenever you can. If you have any questions feel free to ask in |
fixed toxic damage oops there was a bug but its fixed now Delete .vs directory added .vs to gitignore added .vs to gitignore for real this time maybe updated desc.ts Revert "updated desc.ts" This reverts commit 9055601. fixed a bug in predictTotal, and updated the code to match upstream
…t, and fixed a few typos
The rebase is finished. I added some new tests. The tests I added are for generations 3-9.
The reason tests for 1-4HKOs are separate from tests for 5+HKOs is because the calculateKOChance function is used for the former and predictTotal is used for the latter. I also included some tests to ensure that in cases where a defender heals more at the end of the turn than they would lose (holding leftovers, receiving leech seed, etc.), they don't have their HP increased past 0 if the initial hit would have KOed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will merge on Monday. Sorry for the delay.
No need to apologize. Thanks for all the help! |
Great work, thank you! |
Fixed several bugs:
I also changed the way OHKOs are displayed when end of turn damage comes into play. For example, if a move isn't a guaranteed OHKO before end of turn damage, but has a higher chance to OHKO after end of turn damage, the chance to OHKO after end of turn damage is displayed separately. This is for cases where someone's pokemon outspeeds their opponent's pokemon, but their opponent can OHKO and the player wants to see how likely it is for them to KO their opponent before they get attacked. Here's an example: 0 SpA Ivysaur Weather Ball (100 BP Fire) vs. 0 HP / 252 SpD Abomasnow in Sun: 316-376 (98.4 - 117.1%) -- 87.5% chance to OHKO (guaranteed OHKO after poison damage)