Fix missing th, tw in display funcs
This commit is contained in:
parent
15fdb806aa
commit
3877075b46
2
test.lua
2
test.lua
|
@ -25,6 +25,7 @@ local immediate_reload = false
|
||||||
|
|
||||||
|
|
||||||
function requestsDisplay()
|
function requestsDisplay()
|
||||||
|
local tw,th = term.getSize()
|
||||||
for i, val in pairs(requests) do
|
for i, val in pairs(requests) do
|
||||||
local line_num = i-page_start_idx+3
|
local line_num = i-page_start_idx+3
|
||||||
if line_num > 2 and line_num < th then
|
if line_num > 2 and line_num < th then
|
||||||
|
@ -60,6 +61,7 @@ function requestsDisplay()
|
||||||
end
|
end
|
||||||
|
|
||||||
function ordersDisplay()
|
function ordersDisplay()
|
||||||
|
local tw,th = term.getSize()
|
||||||
for i, val in pairs(orders) do
|
for i, val in pairs(orders) do
|
||||||
local line_num = (i-page_start_idx)*2+3
|
local line_num = (i-page_start_idx)*2+3
|
||||||
if line_num > 2 and line_num < th-1 then
|
if line_num > 2 and line_num < th-1 then
|
||||||
|
|
Loading…
Reference in a new issue