I am trying to determine if a player is looking at a chest or not, I have looked through the Entity and the Look helper but I have not seen anything that helps. Is there anything that helps determine what a player is looking at in the code or do I have to get the player facing direction and eye height and mathematically walk the line of site and test for a block at each point until I hit !air or chest.
If so any examples as I am being lazy and my trig is rusty