Answer the question
In order to leave comments, you need to log in
Why is the object not being destroyed?
this is how the object appears on the scene
[SerializeField] private Dictionary<int, Cell> Cells = new Dictionary<int, Cell>();
..........
Cells[Num] = Instantiate(Prefab, new Vector3(x, y, 0), Quaternion.identity) as Cell;
Cells[Num].transform.parent = gameObject.transform;
Cells[Num].name = "Test";
++Num;
Debug.Log(Num);
Destroy(Cells[Num]);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question