make the camera follow the player code example
Example: camera follow
public Transform player;
public Vector3 offset;
void LateUpdate()
{
transform.position = player.position + offset;
}
public Transform player;
public Vector3 offset;
void LateUpdate()
{
transform.position = player.position + offset;
}