From 9f04510c9bf75e31f3457a7900bff4ebd7a080b0 Mon Sep 17 00:00:00 2001 From: MrZ626 <1046101471@qq.com> Date: Tue, 20 Apr 2021 01:03:48 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AE=80=E5=8C=96ws-app=E7=9A=84update?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=EF=BC=8C=E4=B8=8D=E5=86=8D=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E9=87=8D=E8=BF=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- parts/net.lua | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/parts/net.lua b/parts/net.lua index fd9f783b..9235d854 100644 --- a/parts/net.lua +++ b/parts/net.lua @@ -218,11 +218,9 @@ end --WS tick funcs function NET.updateWS_app() - local retryTime=3 while true do YIELD() - local status=WS.status("app") - if status=="running"then + if WS.status("app")=="running"then local message,op=WS.read("app") if message then if op=="ping"then @@ -260,11 +258,6 @@ function NET.updateWS_app() end end end - elseif status=="dead"then - retryTime=retryTime-1 - if retryTime==0 then return end - for _=1,180 do YIELD()end - WS.connect("app","/app") end end end