Here is the great article to explain those to. How to make any player or object look at and rotate towards the mouse cursor! While i draw circles with the mouse, it will do full rotations, but not consistently point to where the mouse is
I'm not sure as to why //this is a unity script (c#), this script is able for you to look around The desired result is for the camera (child of player object) to follow the players movement and rotation, while the player moves with its movement script, and rotates to point true to where the mouse is.
Specifically using the lookat method for exactly that purpose. I have the player movement down and the camera following the player But how do i make the character look at where the mouse is This is the script i currently have, found it on another thread but didn’t work for me
Learn how to use the mouse position with other objects in unity in 2d Including how to rotate & move objects to follow the mouse on screen.