In our game, we perform a raycast in 3D space based on the location of the cursor in screen space. We want to cache the results of this raycast for different uses so we're not performing the same raycast in multiple place. We want the results to be as accurate as possible from the player's perspective. We don't want to present information to the player based on the results of this ray trace that are fast or slow by one frame.
The meat of this question is:
In what object and function should we perform this raycast and save the results?
We're unfamiliar with the order that different objects are processed and the order that different udpate functions are called. Thank you for your help.