blob: 2d2973e89e82d870054a4478f9838336904d828a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
sres =textutils.unserializeJSON( http.post("https://krist.dev/ws/start","").readAll())
assert(sres.ok,"not ok")
ws = assert(http.websocket(sres.url))
while true do
c=textutils.unserializeJSON(assert((ws.receive())))
print(c.type)
end
-- mtop = peripheral.wrap"top"
-- while true do
-- mtop.setTextScale(3.5)
-- mtop.setTextColor(colors.cyan)
-- mtop.setCursorPos(1,1)
-- mtop.write"DIAMONDS"
-- os.sleep(0.75)
-- mtop.clear()
-- os.sleep(0.25)
-- mtop.setTextScale(3)
-- mtop.setTextColor(colors.white)
-- mtop.setCursorPos(1,1)
-- mtop.write("5KST EACH")
-- os.sleep(0.75)
-- mtop.clear()
-- os.sleep(0.25)
-- end
|