聊天室不会按一次esc就退出

This commit is contained in:
MrZ626
2020-12-07 21:28:12 +08:00
parent 88a5e50256
commit 96987add7b
5 changed files with 11 additions and 1 deletions

View File

@@ -96,6 +96,7 @@ return{
-- chatRemain="人数:",
-- chatStart="------消息的开头------",
-- chatHistory="------以上是历史消息------",
-- chatQuit="再按一次退出",
errorMsg="An error has occurred and Techmino needs to restart.\nError info has been created, and you can send it to the author.",

View File

@@ -99,6 +99,7 @@ return{
-- chatRemain="人数:",
-- chatStart="------消息的开头------",
-- chatHistory="------以上是历史消息------",
-- chatQuit="再按一次退出",
errorMsg="Une erreur est survenue et Techmino doit redémarrer.\nDes informations concernant l'erreur ont été créées, et vous pouvez les envoyer au créateur.",

View File

@@ -100,6 +100,7 @@ return{
-- chatRemain="人数:",
-- chatStart="------消息的开头------",
-- chatHistory="------以上是历史消息------",
-- chatQuit="再按一次退出",
errorMsg="Ha ocurrido un error y Techmino necesita reiniciarse.\nSe creó un registro de error, puedes enviarlo al autor.",

View File

@@ -97,6 +97,7 @@ return{
chatRemain="人数:",
chatStart="------消息的开头------",
chatHistory="------以上是历史消息------",
chatQuit="再按一次退出",
errorMsg="Techmino遭受了雷击,需要重新启动.\n我们已收集了一些错误信息,你可以向作者进行反馈.",

View File

@@ -9,6 +9,7 @@ local remain--People in chat room
local scroll--Bottom message no.
local newMessage=false--If there is a new message
local heartBeatTimer
local escapeTimer=0
local function focusAtTextbox()
coroutine.yield()
@@ -66,7 +67,12 @@ function scene.keyDown(k)
elseif k=="return"then
sendMessage()
elseif k=="escape"then
SCN.back()
if Timer()-escapeTimer<.6 then
SCN.back()
else
escapeTimer=Timer()
LOG.print(text.chatQuit,COLOR.orange)
end
else
WIDGET.keyPressed(k)
end