Fivem Raycast For Achieving The Exact Coords That Player Is Looking At

Hello Im New To Fivem Developing I Want To Create A CCTV Camera Script But Not Like Others That You Create A Config LUA File And Add The Camera’s Info On The Script So When You Refresh That The Camera Shows Up I Want To Client Can Place Camera’s Around Himselft And I Think I Need A Raycast Function That Collision With The Object Or Wall That Client Is Looking At And The Coordinates Of That Spot On That Object Is Achievable With Raycast So I Can Put Object xyz Inside ( CreateCam Native )

If You Want More Information

This Video Between 0.10S - 0.30S