diff options
Diffstat (limited to 'internet.lua')
| -rw-r--r-- | internet.lua | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/internet.lua b/internet.lua index 98ce15c..375b4cf 100644 --- a/internet.lua +++ b/internet.lua @@ -58,6 +58,21 @@ function updateInternet() win[2].update = true internet.load = 0 end + if key == "backspace" and layer[1] == 1 and v1.yes == false then + chat.msg = string.sub(chat.msg, 1, string.len(chat.msg)-1) + if chat.msg ~= chat.msgold then + win[1].update = true + chat.blink = true + chat.blinkTimer = 0.5 + end + end + if key == "return" and layer[1] == 1 and chat.msg ~= "" then + sendMessage(2, chat.msg) + if chat.status == 1 then + chatReply(string.lower(chat.msg)) + end + chat.msg = "" + end end function love.textinput(t) if layer[1] == 2 and v1.yes == false then @@ -68,6 +83,16 @@ function updateInternet() internet.blinkTimer = 0 end end + if layer[1] == 1 and v1.yes == false then + if string.len(chat.msg) < 18 then + chat.msg = chat.msg .. t + end + if chat.msg ~= chat.msgold then + win[1].update = true + chat.blink = true + chat.blinkTimer = 0.5 + end + end end if internet.load ~= 442 then if math.random(1,3) == 3 then |
