Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local ss = { "top", "bottom", "left", "right", "front", "back"}
- pt = nil
- local arg = {...}
- for i = 1, #ss do
- if peripheral.isPresent(ss[i]) then
- --print(peripheral.getType(ss[i]).." is on the "..ss[i])
- if peripheral.getType(ss[i]) == "printer" then
- pt = peripheral.wrap(ss[i])
- end
- end
- end
- if pt.newPage() then
- pt.write(arg[1])
- pt.endPage()
- else
- error("Coud not print: Check printer")
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement