for some reason it loses focus and there seems to be a scaled offset.
Here is the graph:
here is what happens:
working spot:
loses focus gradually:
How do i fix this gradual offset? I can’t figure out how to calculate it correctly.
The graph basically equals this in c#:
Camera minimapCam;
void Test()
{
RaycastHit hitinfo;
Ray rayy = minimapCam.ScreenPointToRay(Input.mousePosition);
if (Physics.Raycast(rayy, out hitinfo))
{
Camera.main.transform.position = new Vector3(hitinfo.point.x, Camera.main.transform.position.y, hitinfo.point.z - 75);
}
}