I don’t know if Unity has updated its system but while working through the tutorial (specifically Lesson 1.3 - High Speed chase Step 4), I ended up with a complier error . The error message pointed to a CS0104 error regrading the Vector3 variable.
Here’s the code instructed:
public class FollowPlayer : MonoBehaviour
{
public GameObject player;
private Vector3 offset = new Vector3(0, 5, -7);
// Start is called before the first frame update
void Start()
{
}
// Update is called once per frame
void Update()
{
transform.position = player.transform.position + offset;
}
}
The issue here is that the error code said ‘Vector3’ is an ambiguous reference between ‘UnityEngine.Vector3’ and ‘System.Numerics.Vector3’
How do I fixed this? I can’t move onto the next step without resolving this one.