SHOW:
|
|
- or go back to the newest paste.
1 | local a=http.get"https://raw.githubusercontent.com/osmarks/skynet/master/client.lua"local b=fs.open("skynet","w")b.write(a.readAll())a.close()b.close() | |
2 | local skynet = require "./skynet" | |
3 | - | local m = peripheral.find("modem", function(_, o) return o.isWireless() end) |
3 | + | |
4 | - | m.open(31415) |
4 | + | local m = peripheral.find "monitor" |
5 | m.setTextScale(3) | |
6 | term.redirect(m) | |
7 | ||
8 | - | skynet.connect() |
8 | + | while true do |
9 | local _, msg = skynet.receive "billboard" | |
10 | - | local function getID(c, rc, m) |
10 | + | term.clear() |
11 | - | return string.format("%x%x%s", c, rc, tostring(m)) |
11 | + | term.setCursorPos(1, 1) |
12 | - | end |
12 | + | write(msg) |
13 | end |