protected virtual void Sheep_OnSelection(SheepSelector s) { currentSheep = s.GetController(); if (currentSheep != null) { currentSheep.OnMoveOrder += Sheep_OnMoveOrder; followToggle.SetIsOnWithoutNotify(currentSheep.IsFollowing()); lookToggle.SetIsOnWithoutNotify(currentSheep.IsLookingOut()); } }
protected virtual void Sheep_OnDeselection(SheepSelector s) { currentSheep.OnMoveOrder -= Sheep_OnMoveOrder; currentSheep = null; }
void SheepSelector_OnDeselection(SheepSelector s) { Debug.Log("[Sheep] OnDeselection: " + name); isSelected = false; OnDeselect?.Invoke(); }