예제 #1
0
    public static void AddListersToSpeed(UnityAction <int, int> listener)
    {
        speedListeners.Add(listener);

        if (invoker != null)
        {
            foreach (UnityAction <int, int> item in speedListeners)
            {
                invoker.AddListenerToSpeed(item);
            }
        }
    }
예제 #2
0
    public static void AddInvoker(PickUpBlock script)
    {
        invoker = script;

        if (freezerListners != null)
        {
            invoker.AddListenerToFreezer(freezerListners);
        }
        foreach (UnityAction <int, int> item in speedListeners)
        {
            invoker.AddListenerToSpeed(item);
        }
    }