30 lines
629 B
Text
30 lines
629 B
Text
W = window.create(term.native(),3,3,39,13)
|
|
function thiefmirror()
|
|
while true do
|
|
id,mess = rednet.receive()
|
|
if id == 3 then
|
|
W[mess[1]](unpack(mess[2]))
|
|
end
|
|
end
|
|
end
|
|
function eventmirror()
|
|
while true do
|
|
event = {os.pullEventRaw()}
|
|
if event[1] == "rednet_message" then
|
|
|
|
elseif event[1] == "modem_message" then
|
|
|
|
else
|
|
rednet.send(
|
|
3,
|
|
event,
|
|
"pocketevent"
|
|
)
|
|
--print(event)
|
|
end
|
|
end
|
|
end
|
|
parallel.waitForAll(
|
|
thiefmirror,
|
|
eventmirror
|
|
)
|