瀏覽代碼

增加WaitSendWebRequest

jiangxufeng 3 年之前
父節點
當前提交
56837151a2
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      LuaDemo/Assets/BundleResource/LuaScripts/Base/CoroutineHelper.lua.txt

+ 4 - 0
LuaDemo/Assets/BundleResource/LuaScripts/Base/CoroutineHelper.lua.txt

@@ -44,6 +44,10 @@ function CoroutineHelper:WaitForEndOfFrame()
     coroutine.yield(CS.UnityEngine.WaitForEndOfFrame())
 end
 
+function CoroutineHelper:WaitSendWebRequest(luaRequest)
+    coroutine.yield(luaRequest:SendWebRequest())
+end
+
 function CoroutineHelper:Test()
     local targetCoroutine = CoroutineHelper.Start(
         function()