Hello,
i’m working on my first Unity “game”.
In my coding I now got a problem. I get the Error message “NullReferenceException: Object reference not set to an instance of an object”.
Even after asking uncle google i could not solve my problem.
if (count == 1 && run == 0) {
StartCoroutine (WallTime ());
// problem
GameObject.FindWithTag ("door closed").SetActive (false);
Debug.Log (" ");
GameObject.FindWithTag ("door opened").SetActive (true);
//problem
//Instantiate (wall2, new Vector3 (13.93f, -0.19f, 4.2f), Quaternion.identity);
//Instantiate (wall2, new Vector3 (13.93f, -0.19f, -4.403705f), Quaternion.identity);
//, new Quaternion (0, 180, 0, 0)
run = 1;
}
thx