Ejemplo n.º 1
0
 static async void Req(string url)
 {
     using (UnityWebRequestAsync webRequestAsync = ETModel.ComponentFactory.Create <UnityWebRequestAsync>())
     {
         await webRequestAsync.DownloadAsync(url);
     }
 }
Ejemplo n.º 2
0
        public static async Task Req(string url, CallBack callback)
        {
            using (UnityWebRequestAsync webRequestAsync = ETModel.ComponentFactory.Create <UnityWebRequestAsync>())
            {
                await webRequestAsync.DownloadAsync(url);

                callback(webRequestAsync.Request.downloadHandler.text);
            }
        }