Knockback enchantment doesn't apply in PVP
Verification Builds: 1.13.1 and 1.14.1
Summary: Knockback enchantment doesn't knock other players +3 / +6 blocks further back, it only works on mobs(both types)
Impact: Players are not knocked back further despite having the enchantment
Repro Steps:
1. In Creative mode give yourself two swords, an anvil, and a knockback book. Enchant one sword with Knockback
2. Spawn in any mob. Hit with a normal sword and with a knockback sword. Observe that the knockback works on mobs.
3. Invite a second player into the world. Ensure they are not in Creative mode and that /gamerule PVP is true. Hit with a normal sword and with a knockback sword. The player will travel the same distance regardless of the knockback enchantment
Observed Results:
This seems to be a problem with the Knockback enchantment interacting with players regardless of what item the enchantment is on. I used an editor to enchant a stick with Knockback II and it behaves how I expect- the enchanted stick sends mobs 6 blocks further than a regular stick does. Players still travel the same distance when hit by a regular stick and a Knockback II stick. This scales with enchantment level- you can use the editor to give the stick Knockback 999 which immediately sent the villager I hit out of the 80 chunk render distance, but players still travel the ~3 blocks when hit by the Knockback 999 stick(tested on 1.14)
Expected Results: Hitting a player with an item enchanted with Knockback should move a player further back than hitting them with a normal item.
Screenshots/Videos attached:
No