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

Berserker doesn't activate if mon hit's exactly half hp #349

Open
StephenLynx opened this issue Oct 1, 2022 · 0 comments
Open

Berserker doesn't activate if mon hit's exactly half hp #349

StephenLynx opened this issue Oct 1, 2022 · 0 comments
Labels
bug Something isn't working confirmed Bug/issue confirmed with test or code check

Comments

@StephenLynx
Copy link

On battle_util it checks like so:
gBattleStruct->hpBefore[battler] > gBattleMons[battler].maxHP / 2
&& gBattleMons[battler].hp < gBattleMons[battler].maxHP / 2

So if it hits exactly half hp, it won't trigger in the same turn because of the second check, the next one it will fail the first check. I fixed this on https://gitgud.io/stephenlynx/pokemonie/-/commit/1ad25d09151919379a02f45f3fcec20146ad5c72

@StephenLynx StephenLynx changed the title Bersker doesn't activate if mon hit's exactly half hp Berserker doesn't activate if mon hit's exactly half hp Oct 1, 2022
@BuffelSaft BuffelSaft added bug Something isn't working confirmed Bug/issue confirmed with test or code check labels Oct 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working confirmed Bug/issue confirmed with test or code check
Projects
None yet
Development

No branches or pull requests

2 participants