예제 #1
0
        /// <summary>
        /// MonoBehaviour Update
        /// </summary>
        private void Update()
        {
            var transport = PluginManager.GetPlugin <ITransportPlugin>(PluginContract.PlayFab_Transport);

            if (transport.IsInitialized)
            {
                if (_apiCallQueue != null)
                {
                    foreach (var eachRequest in _apiCallQueue)
                    {
                        transport.MakeApiCall(eachRequest); // Flush the queue
                    }
                    _apiCallQueue = null;                   // null this after it's flushed
                }
                transport.Update();
            }

#if ENABLE_PLAYFABPLAYSTREAM_API && ENABLE_PLAYFABSERVER_API
            if (_internalSignalR != null)
            {
                _internalSignalR.Update();
            }
#endif
#if NET_4_6
            while (_injectedCoroutines.Count > 0)
            {
                StartCoroutine(_injectedCoroutines.Dequeue());
            }

            while (_injectedAction.Count > 0)
            {
                _injectedAction.Dequeue()?.Invoke();
            }
#endif
        }
예제 #2
0
        /// <summary>
        /// MonoBehaviour Update
        /// </summary>
        public void Update()
        {
            if (_internalHttp != null)
            {
                if (!_internalHttp.SessionStarted && _apiCallQueue != null)
                {
                    foreach (var eachRequest in _apiCallQueue)
                    {
                        _internalHttp.MakeApiCall(eachRequest); // Flush the queue
                    }
                    _apiCallQueue = null;                       // null this after it's flushed
                }
                _internalHttp.Update();
            }

#if ENABLE_PLAYFABPLAYSTREAM_API && ENABLE_PLAYFABSERVER_API
            if (_internalSignalR != null)
            {
                _internalSignalR.Update();
            }
#endif
        }
예제 #3
0
        /// <summary>
        /// MonoBehaviour Update
        /// </summary>
        private void Update()
        {
            var transport = PluginManager.GetPlugin <ITransportPlugin>(PluginContract.PlayFab_Transport);

            if (transport.IsInitialized)
            {
                if (_apiCallQueue != null)
                {
                    foreach (var eachRequest in _apiCallQueue)
                    {
                        transport.MakeApiCall(eachRequest); // Flush the queue
                    }
                    _apiCallQueue = null;                   // null this after it's flushed
                }
                transport.Update();
            }

#if ENABLE_PLAYFABPLAYSTREAM_API && ENABLE_PLAYFABSERVER_API
            if (_internalSignalR != null)
            {
                _internalSignalR.Update();
            }
#endif
        }