Example #1
0
 public static void Add(DelayedDelegateGameObject method, GameObject param, float delay)
 {
     PreAdd();
     delayedDelegatesGameObject.Add(method);
     delayedDelegatesTimeGameObject.Add(Time.fixedTime + delay);
     delegateParametersGameObject.Add(param);
 }
Example #2
0
    public static void RunAll(DelayedDelegateGameObject method)
    {
        for (int x = delayedDelegatesGameObject.Count - 1; x >= 0; x--)
        {
            if (delayedDelegatesGameObject[x] == method)
            {
                delayedDelegatesTimeGameObject[x] = Time.fixedTime;
            }
        }

        DelayedDelegates.RunDelegates();
    }
Example #3
0
 public static void RemoveAll(DelayedDelegateGameObject method)
 {
     for (int x = delayedDelegatesGameObject.Count - 1; x >= 0; x--)
     {
         if (delayedDelegatesGameObject[x] == method)
         {
             delayedDelegatesGameObject.RemoveAt(x);
             delayedDelegatesTimeGameObject.RemoveAt(x);
             delegateParametersGameObject.RemoveAt(x);
         }
     }
 }