예제 #1
0
 public void UnsubscribeFromCurrencyChange(CurrencyType type, MonoActionInt callback)
 {
     if (hasCurrencySystem)
     {
         currencies.UnsubscribeFromCurrencyChange(type, callback);
     }
 }
예제 #2
0
    void bufferChangeCurrencyDelegate(CurrencyType type, MonoActionInt callback)
    {
        Queue <MonoActionInt> bufferedCallbacks;

        if (!currencyChangeDelegateBuffers.TryGetValue(type, out bufferedCallbacks))
        {
            bufferedCallbacks = new Queue <MonoActionInt>();
        }
        bufferedCallbacks.Enqueue(callback);
    }
예제 #3
0
 public void SubscribeToCurrencyChange(CurrencyType type, MonoActionInt callback)
 {
     if (hasCurrencySystem)
     {
         currencies.SubscribeToCurrencyChange(type, callback);
     }
     else
     {
         bufferChangeCurrencyDelegate(type, callback);
     }
 }
예제 #4
0
 public void UnsubscribeFromCurrencyChange(CurrencyType type, MonoActionInt callback)
 {
     dataController.UnsubscribeFromCurrencyChange(type, callback);
 }
예제 #5
0
 public void SubscribeToCurrencyChange(CurrencyType type, MonoActionInt callback)
 {
     dataController.SubscribeToCurrencyChange(type, callback);
 }