Ejemplo n.º 1
0
 public void UseItem <TItem>(Item.ItemDelegate didStart = null, Item.ItemDelegate didAction = null, Item.ItemDelegate didEnd = null)
 {
     foreach (var kvPair in Items)
     {
         if (typeof(TItem) == kvPair.Value.GetType())
         {
             StartCoroutine(kvPair.Value.Execute(didStart, didAction, didEnd));
             return;
         }
     }
 }
Ejemplo n.º 2
0
 public void UseItem(string itemClassName, Item.ItemDelegate didStart = null, Item.ItemDelegate didAction = null, Item.ItemDelegate didEnd = null)
 {
     StartCoroutine(Items[itemClassName].Execute(didStart, didAction, didEnd));
 }