Replies: 1 comment 3 replies
-
|
Would fit well on PreAttack yea. Arrows already have a setter so, that ought to work out. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem?
Currently, there is no way to prevent critical damage for specific damage instances. Simply if the conditions for crit are met, it will be crit, otherwise, it won't. You can disable it in config, but that's too global.
Describe the solution you'd like.
Currently, there are two events revolving player attack: PrePlayerAttackEntityEvent and EntityDamageByEntityEvent.
Former is too soon for decision of crits and the latter is too late.
I would suggest adding something like preventCriticalHit() method to PrePlayerAttackEntityEvent, which would prevent the whole crit logic.
I will gladly make a PR for that, but wanted to ask whether something like this has chance on being accepted, before I start working on it...
Describe alternatives you've considered.
I could use PrePlayerAttackEntityEvent to give player a Blindness effect, prevent blindness packets from being sent to the player, then removing the effect in DamageEvent... But that is way too hacky with many potential issues...
Other
No response
Beta Was this translation helpful? Give feedback.
All reactions