public virtual void CollectItem(TriggerGenericAction action) { var collection = action.GetComponentInChildren <ItemCollection>(); if (collection != null) { collection.CollectItems(this); } }
public virtual void CollectItem(TriggerGenericAction action) { var collection = action.GetComponentInChildren <ItemCollection>(); if (collection != null) { if (collection.items.Count > 0) { var itemCol = collection.items.vCopy(); StartCoroutine(CollectItemsWithDelay(itemCol, collection.onCollectDelay, collection.textDelay, collection.immediate)); } } }