fabric-carpet icon indicating copy to clipboard operation
fabric-carpet copied to clipboard

incorrect reach distance for /player attack

Open AndrewScripter587 opened this issue 6 months ago • 0 comments

When running the command "/player (name) attack", the player reaches further than it should (in survival at least, and yes i tested this with a survival mode fake player). the command will make a player/fake player attack an entity further than is possible for a normal player (from my testing it is about 0.5 to 1 block further).

Steps to reproduce:

  1. place a mob or entity or spawn a fake player in survival mode or adventure mode
  2. Go to survival mode.
  3. move yourself to a spot where the mob/entity/fake player is just barely out of normal survival mode reach
  4. look at the mob/entity/fake player
  5. attempt to normally attack it without moving. you should find that nothing happens because it is out of normal reach
  6. run "/player (name) attack" on yourself
  7. observe that you successfully hit the mob/entity/fake player even though it is just out of normal reach

And yes this also happens with "/player (name) attack" run on a fake player as well, it was just easier to demonstrate with myself.

Minecraft Version: Release 1.20.4 Fabric Loader Version: 0.16.0 Carpet Version: 1.4.128 Allocated RAM: 5632 MB Using the modrinth app to run minecraft

Video (sorry for no audio i guess snipping tool didn't record the audio): https://github.com/user-attachments/assets/f6901dda-004a-40ac-bbfc-ffa9703de167

AndrewScripter587 avatar Aug 06 '24 12:08 AndrewScripter587