private void Awake() { dataProvider = GetComponent <RoamingDefenceDataProvider>(); defence = GetComponent <RoamingDefense>(); planetFromSnapper.snapped += SnapPlanetFrom; planetToSnapper.snapped += SnapPlanetTo; //Detaching vfx from the object itself for it to not move with the object pathObject.transform.SetParent(null); }
protected override void Awake() { base.Awake(); dataProvider = GetComponent <RoamingDefenceDataProvider>(); }