Advertisement
logit667

Monitor-Flash

Jul 24th, 2014
230
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.42 KB | None | 0 0
  1. --Term setup
  2. x=0
  3. local term = peripheral.wrap("top")
  4. term.clear()
  5. --term.setBackgroundColour(colours.black)
  6.  
  7. while true do
  8.     if redstone.getInput("bottom") then
  9.         if x==0 then
  10.             term.setBackgroundColour(colours.black)
  11.             term.clear()
  12.             x=1
  13.         else
  14.             term.setBackgroundColour(colours.red)
  15.             term.clear()
  16.             x=0
  17.         end
  18.     else
  19.         term.setBackgroundColour(colours.green)
  20.         term.clear()
  21.         x=0
  22.     end
  23.     os.sleep(1)
  24. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement