public void Refesh(int _refeshIndex) { if (_refeshIndex == mRefeshIndex) { return; } mRefeshIndex = _refeshIndex; mGroupID = 0; for (int i = 0; i < mListNode.Count; i++) { if (mListNode[i] == null) { mListNode.RemoveAt(i); i--; } else { mListNode[i].Refesh(_refeshIndex); } } for (int i = 0; i < transform.childCount; i++) { Transform child = transform.GetChild(i); PathNodeEditor nodechild = child.GetComponent <PathNodeEditor>(); if (nodechild != null) { nodechild.Refesh(_refeshIndex); } } }
public void Refesh() { mRefeshIndex++; for (int i = 0; i < transform.childCount; i++) { Transform trans = transform.GetChild(i); PathNodeEditor nodeeditor = trans.GetComponent <PathNodeEditor>(); if (nodeeditor != null) { nodeeditor.Refesh(mRefeshIndex); } } }