How would you detect if a hit is critical? I know that you can use velocity but hacked clients (i am making an anticheat) don't seem to do the little jumps they used to when doing a crit. I know there is a way with NMS but i'm not really sure on what it is.
@dlange You can check to see if the damage dealt is greater than normal, meaning critical, then just check to see if their Y velocity is negative to see if they were supposed to deal a critical.
@567legodude Oh yeah that should work haha don't know how i didn't think about that XD Thanks a lot man EDIT: JUST realised that i will have to add checks for every combination of every armour type. Very inefficient imo, if anyone else has other ideas, let me know
@dlange The EntityDamageByEntityEvent should have a method to get the amount of damage dealt before accounting for enchantments/armor (I believe). All you really need to check for is the type of weapon they are holding. EDIT: Should be event.getDamage() to get damage before any reduction is applied.
@567legodude Alright cheers, ill look into it EDIT: Sweet, i found a way implementing that Thanks a lot!