Advertisement
SythsGod

Wither Redstone Program

Jan 29th, 2015
211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.53 KB | None | 0 0
  1. rednet.close("bottom")
  2. rednet.open("bottom")
  3.  
  4. local white = 1
  5. local blue = 2048
  6. local green = 8192
  7.  
  8. function bundled(color, side)
  9.   rs.setBundledOutput(side, color)
  10.   sleep(1)
  11.   rs.setBundledOutput(side, 0)
  12. end
  13.  
  14. while true do
  15.   local sndrId, msg, dist, prot = rednet.receive("UPDATE")
  16.   -- Send redstone signals according to current status
  17.   if msg == "BUILD" then
  18.     bundled(white, "top")
  19.   elseif msg == "REDST" then
  20.     bundled(blue, "top")
  21.   elseif msg == "END" then
  22.     bundled(green, "top")
  23.   end
  24.   sleep(1)
  25. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement