public void AddBeeToSwarm(Bee bee) { Swarm.Add(bee); _interactables.RemoveInteractable(bee); bee.SetPlayerSkin(this); }
public bool CatchSheep() { if (!HasCapacity) { return(false); } Sheep caught = null; foreach (Sheep sheep in _interactables) { if (null != sheep && sheep.CanCatch) { caught = sheep; break; } } if (null == caught) { return(false); } if (null == _carrying) { if (!GrabSheep(caught)) { return(false); } } else if (!caught.IsInQueue && !_onPlatform) { EnqueueSheep(caught); } else { return(false); } Debug.Log($"Caught sheep {caught.Id}"); GameManager.Instance.OnSheepCollected(); _interactables.RemoveInteractable(caught); return(true); }