I 'fixed' the stupid fastty bug, get a faster display by setting _G.term_hack to false
This commit is contained in:
parent
dcf5cf7c35
commit
d37cc4a155
@ -1,7 +1,8 @@
|
||||
_G.term_hack = true
|
||||
function tty(gA,sA,sI,mx,my)
|
||||
spawn("fastty: "..gA:sub(1,8)..","..sA:sub(1,8)..","..sI,function()
|
||||
-- _G.nlog = ""
|
||||
local sb,lb = {},{}
|
||||
_G.nlog = ""
|
||||
local sb,lb,slb = {},{},{}
|
||||
local cx, cy = 1, 1
|
||||
local sI = sI or os.getenv("sI")
|
||||
local gpu = component.proxy(gA)
|
||||
@ -48,17 +49,16 @@ function tty(gA,sA,sI,mx,my)
|
||||
end
|
||||
for i = 1, sy do
|
||||
if sb[i] and sb[i] ~= lb[i] then
|
||||
if not sb[i] then
|
||||
lb[i] = nil
|
||||
else
|
||||
--lb[i] = sb[i]
|
||||
end
|
||||
lb[i] = sb[i]
|
||||
local cs = sb[i]
|
||||
--nlog = nlog .. tostring(i) .. " " .. tostring(cs) .. "\n"
|
||||
while cs:len() < sx do
|
||||
cs=cs.." "
|
||||
end
|
||||
gpu.set(1,i,cs)
|
||||
if term_hack then
|
||||
gpu.set(1,i,cs)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user