public ED_ActorPathCom CreatePath() { Transform pathTrans = transform.Find("Prefab/Path"); GameObject newGo = MapEditorHelper.CreateObj(pathTrans.gameObject, PathRoot.gameObject); ED_ActorPathCom pathCom = newGo.GetComponent <ED_ActorPathCom>(); pathCom.pointGo = transform.Find("Prefab/PathPoint").gameObject; return(newGo.GetComponent <ED_ActorPathCom>()); }
public ED_ActorPathPointCom CreatePoint() { GameObject newGo = MapEditorHelper.CreateObj(pointGo, gameObject); return(newGo.GetComponent <ED_ActorPathPointCom>()); }