// Start is called before the first frame update void Start() { animator = GetComponent <SelfAnim>(); allPoints = new Vector3[pathParent.childCount]; for (int i = 0; i < pathParent.childCount; i++) { allPoints[i] = pathParent.GetChild(i).position; } currPoint = 0; }
// Start is called before the first frame update void Start() { animator = GetComponent <SelfAnim>(); InitialOnePath(); }
// Start is called before the first frame update void Start() { rigidbody2 = GetComponent <Rigidbody2D>(); animator = GetComponent <SelfAnim>(); }