I know this is a longshot, but I had this idea
so, because movement is entirely handled by the client in java edition, it would be theorhetically possible to have a custom size for the hitbox of an entity. You'd basically detect if the player tries to hit the custom hitbox and automatically move the camera to the nearest point of the ACTUAL hitbox. (then immediately after move it back to where it was)
This would basically work as aim assist for your fist, so maybe just don't make this doable for players
Here is a screenshot of an example of where this would be useful. As you can seem, the hitbox is tiny compared to the model