Advertisement
kyle1320

Untitled

Mar 28th, 2013
36
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. os.loadAPI("spiral")
  2. os.loadAPI("file")
  3. rednet.open("right")
  4.  
  5. parent = 1637
  6.  
  7. while true do
  8. ID, message = rednet.receive()
  9.  
  10. if message == "start" then
  11. state = file.read("state")
  12.  
  13. if state ~= nil then
  14. dists = state[1]
  15. is = state[2]
  16. js = state[3]
  17. end
  18.  
  19. if dists == nil then
  20. dists = 1
  21. end
  22. if is == nil then
  23. is = 1
  24. end
  25. if js == nil then
  26. js = 1
  27. end
  28.  
  29. spiral.start(dists, is, js)
  30. else
  31. rednet.send(parent, message)
  32. end
  33. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement