darkstar
darkstar copied to clipboard
Players get TP return for WS hits that don't deal damage
I have:
- [x] searched existing issues (http://github.com/darkstarproject/darkstar/issues/) to see if the issue I am posting has already been addressed or opened by another contributor
- [x] checked the commit log to see if my issue has been resolved since my server was last updated
Client Version (type /ver
in game) : n/a
Source Branch (master/stable) : master
Additional Information (Steps to reproduce/Expected behavior) :
TP return for weaponskills is calculated by tp/hitsLanded
. This is incremented when a player passes a whiff check for each hit of their weaponskill, and currently does not check the dmg
that was dealt by the hit.
Side note: Per-hit damage isn't checked against Stoneskin at this point either. It is checked against the total damage that is passed into the defender's takeWeaponSkillDamage. Though I'm not sure if this distinction is important for final damage (but duplicated hybrid hits come to mind).
I can't say 100% that zero-per-hit vs zero-over-whole-WS matters for TP return. Or, so long as a weaponskill deals more than zero total damage, if the WS should return TP equivalent to all landed hits, or if it should only return TP for the hits that actually contributed to the total damage. I've been unable to find a clear source.
BUT the player is going to get credit for all non-whiff hits over the entire weaponskill regardless, because no check against final damage is made before returning the number of hits landed back to the calling weaponskill.
(And in my preemptive defense, this isn't my fault...!)
This may be related to #6240
This was fixed in the past according to another issue linked there (at least, similar behavior was). Are you running the newest master? Also, Client version is not n/a as a wrong client version can cause weird issues.
Can what you've linked to not be resolved in the "hitslanded" by adding a if !dmg = 0 before incrementing the variable?