rotation_to_camera Molang query returns incorrect values when camera is above water surface
Partner Rank: 2 (Important)
Verification Builds: 1.21.40, 1.21.50
Regression Builds: -
Summary: rotation_to_camera Molang query returns slightly offset values when camera is entering a water surface.
Affects currently Live Content: Yes
Impact: While the error in returned values is quite small, it is very noticeable when some element is meant to be attached to camera via entity animations. This issue is also visible every time player goes underwater in 1st person. We've received complaints from players that were experiencing this issue in our live content.
Repro Steps:
- Create a new world with attached add-on and enabled cheats
- Run /summon example:bug command in chat
- Look at the entity while camera is entering water surface from above
Observed Results: Entity geometry that's meant to always point to camera direction goes slightly below, when camera begins entering water (see attached video)
Expected Results: Entity geometry will consistently point to the camera direction while camera is entering water
Screenshots/Videos attached: Yes, video is attached
Notes: -