From f9749ac1814fee61ec6c8889eda07d28fcea4378 Mon Sep 17 00:00:00 2001 From: XeonSquared Date: Thu, 11 Jun 2020 14:03:54 +1000 Subject: [PATCH] more draw call optimisation --- module/buffer.lua | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/module/buffer.lua b/module/buffer.lua index fe9cb23..5e3a635 100644 --- a/module/buffer.lua +++ b/module/buffer.lua @@ -261,7 +261,7 @@ function buffer:read(...) io.write("\27[s\27[8m") local pos, buffer = 1, "" local function redraw() - io.write("\27[u"..buffer.." \27[u\27["..tostring((#buffer-pos)+1).."C") + io.write(string.format("\27[u%s \27[u\27[%iC",buffer,(#buffer-pos)+1)) end while true do char = readBytesOrChars(1) @@ -270,14 +270,12 @@ function buffer:read(...) local args = {""} repeat char = readBytesOrChars(1) - --[[ if char:match("%d") then args[#args] = args[#args]..char else args[#args] = tonumber(args[#args]) args[#args+1] = "" end - ]] until not char:match("[%d;]") if char == "C" then -- right if pos > 1 then