Yes, the player shoots a ray from the middle of the screen in order to interact with the items. Also Ricardo is using raycast to check if the player is visible to him or not.