From 35ac6eacbcc9a0fb589796b6df4cd632638ebb09 Mon Sep 17 00:00:00 2001 From: MrZ626 <1046101471@qq.com> Date: Sun, 28 Mar 2021 20:15:36 +0800 Subject: [PATCH] =?UTF-8?q?LOGIN=E5=8F=98=E9=87=8F=E7=A7=BB=E8=87=B3NET?= =?UTF-8?q?=E5=86=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.lua | 2 +- parts/gametoolfunc.lua | 4 ++-- parts/scenes/main.lua | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/main.lua b/main.lua index d0b3add4..f8722495 100644 --- a/main.lua +++ b/main.lua @@ -23,9 +23,9 @@ SAVEDIR=fs.getSaveDirectory() --Global Vars & Settings LOADED=false DAILYLAUNCH=false -LOGIN=false EDITING="" NET={ + login=false, allow_online=false, } ERRDATA={} diff --git a/parts/gametoolfunc.lua b/parts/gametoolfunc.lua index 8830b474..7306cd6f 100644 --- a/parts/gametoolfunc.lua +++ b/parts/gametoolfunc.lua @@ -1068,7 +1068,7 @@ do --[[ register: if response.message=="OK"then - LOGIN=true + NET.login=true USER.name=res.name USER.id=res.id USER.motto=res.motto @@ -1167,7 +1167,7 @@ do local res=JSON.decode(message) if not res then return end if res.message=="Connected"then - LOGIN=true + NET.login=true if res.id then USER.id=res.id USER.authToken=res.authToken diff --git a/parts/scenes/main.lua b/parts/scenes/main.lua index fd117de0..0f074243 100644 --- a/parts/scenes/main.lua +++ b/parts/scenes/main.lua @@ -77,7 +77,7 @@ function scene.keyDown(key) end elseif key=="a"then if testButton(3)then - if LOGIN then + if NET.login then if not NET.allow_online then TEXT.show(text.needUpdate,640,450,60,"flicker") SFX.play("finesseError")