public override void updateItem(GameObject item, int index) { item.name = StringKit.intToFixString(index + 1); LearningSkillSelectItem sc = item.GetComponent <LearningSkillSelectItem> (); Card c = keys [index]; sc.init(c, map [c]); }
public override void initButton(int i) { if (nodeList [i] == null) { nodeList [i] = NGUITools.AddChild(gameObject, itemPrefab); } nodeList [i].name = StringKit.intToFixString(i + 1); LearningSkillSelectItem sc = nodeList [i].GetComponent <LearningSkillSelectItem> (); sc.window = fatherWindow as LearnSkillSelectWindow; Card c = keys [i]; sc.init(c, map [c]); }