Advertisement
koki2000

PC2

Nov 11th, 2015
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.51 KB | None | 0 0
  1. local id = os.getComputerID()
  2. local valasz = true
  3. local szamol = 1
  4. rednet.close()
  5. rednet.open("back")
  6. print("send1")
  7.  
  8. function clear()
  9.  term.clear()
  10.  term.setCursorPos(1,1)
  11. end
  12.  
  13. while valasz do
  14. rednet.send(8 , id)
  15. senderId, message = rednet.receive(1)
  16.   clear()
  17.   print("proba: ", szamol)
  18.   szamol = szamol + 1
  19.   rs.setOutput("bottom", true)
  20.  if id == message then
  21.   rs.setOutput("bottom", false)
  22.   rs.setOutput("top", true)
  23.   print("visszaigazolva!") sleep(.5)
  24.   rs.setOutput("top", false)
  25.  end
  26. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement