Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local image = require('image')
- local event = require('Event')
- local raid = 'c50'
- local cmp = require('component')
- local modem = cmp.modem
- modem.open(1)
- local ms = require('ms')
- local wk = {}
- function draw()
- i = #wk
- require('component').gpu.set(1,25,'draw')
- while i > 0 do
- ms.draw(wk[i][2],wk[i][3],wk[i][1])
- print(wk[i][2],wk[i][3],wk[i][1])
- i = i - 1
- end
- end
- while true do
- _,_,_,_,_, e1,e2,e3,e4,e5 = event.pull(99999,'modem_message')
- if e1 == 'image' then
- if e2 == 'set' then
- wk[#wk+1] = {'/Mounts/'..get(raid)..'/'..e3,e4,e5,#wk+1}
- draw()
- modem.broadcast(1,'image','set',#wk)
- end
- if e2 == 'remove' then
- wk[e3] = nil
- draw()
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement