public static UICommandLabelButton Instantiate(UICommandLabelButton prefab, Transform parent, Vector3 pos, int nIndex, BattleCommand iCommand, Func <bool> onSetCommand) { UICommandLabelButton uICommandLabelButton = UnityEngine.Object.Instantiate(prefab); uICommandLabelButton.transform.parent = parent; uICommandLabelButton.transform.localScaleOne(); uICommandLabelButton.transform.localPosition = pos; uICommandLabelButton.Init(nIndex, isValid: true, iCommand, onSetCommand); return(uICommandLabelButton); }
public static UICommandLabelButton Instantiate(UICommandLabelButton prefab, Transform parent, Vector3 pos, int nIndex, BattleCommand iCommand, Func <bool> onSetCommand) { UICommandLabelButton uICommandLabelButton = Object.Instantiate <UICommandLabelButton>(prefab); uICommandLabelButton.get_transform().set_parent(parent); uICommandLabelButton.get_transform().localScaleOne(); uICommandLabelButton.get_transform().set_localPosition(pos); uICommandLabelButton.Init(nIndex, true, iCommand, onSetCommand); return(uICommandLabelButton); }