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

🐛 [Bug] Custom Damage / Healing Config in WorldServer Double Dips #339

Open
drikishuk opened this issue Sep 14, 2024 · 0 comments
Open
Labels
bug Something isn't working

Comments

@drikishuk
Copy link

🐛 Bug report

Set for example Arcane Mage damage config to 0.25, the values showed in combat log / floating combat text are correct, however the true damage values and calculations server side are actually double dipped.
For example 100 damage at 0.25 should be 25 damage.
Instead we get 100 x 0.25 x 0.25 = 6.25 total damage.

This is due to an awkward implementation for spells only that use this function:
uint32 Unit::RecaculateDamage(uint32 damage)

This is called once in Unit::DealDamage but is also called in: HandlePeriodicDamageAurasTick()

HandlePeriodicDamageAurasTick calls Unit::DealDamage therefore the calculation double dips.

Potential hack fix is just passing another param to Unit::DealDamage that says whether it has been re-calculated yet or not and check if this is true and decide whether to call it inside Unit::DealDamage.

@drikishuk drikishuk added the bug Something isn't working label Sep 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant