From 134773765c70bd3dee8b07648c2d3655b309a07f Mon Sep 17 00:00:00 2001 From: MrZ_26 <1046101471@qq.com> Date: Mon, 24 Oct 2022 23:29:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=88=9B=E5=BB=BA=E6=88=BF=E9=97=B4?= =?UTF-8?q?=E5=9C=BA=E6=99=AF=E5=9C=A8=E5=9C=BA=E6=99=AF=E6=A0=88=E7=9A=84?= =?UTF-8?q?=E4=BD=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- parts/net.lua | 1 + parts/scenes/net_game.lua | 10 +++------- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/parts/net.lua b/parts/net.lua index 66c6cc86..9a2da600 100644 --- a/parts/net.lua +++ b/parts/net.lua @@ -590,6 +590,7 @@ end function NET.wsCallBack.room_create(body) MES.new('check',text.createRoomSuccessed) NET.wsCallBack.room_enter(body) + SCN.pop() WAIT.interrupt() end function NET.wsCallBack.room_getData(body) diff --git a/parts/scenes/net_game.lua b/parts/scenes/net_game.lua index 3cf2d954..e00204e4 100644 --- a/parts/scenes/net_game.lua +++ b/parts/scenes/net_game.lua @@ -48,9 +48,6 @@ end local function _quit() if tryBack() then NET.room_leave() - if SCN.stack[#SCN.stack-1]=='net_newRoom' then - SCN.pop() - end SCN.back() end end @@ -148,10 +145,9 @@ function scene.keyDown(key,isRep) else NET.textBox:push{COLOR.R,'Invalid command'} end - else - if NET.room_chat(mes) then - inputBox:clear() - end + inputBox:clear() + elseif NET.room_chat(mes) then + inputBox:clear() end else _switchChat()