Guest User

Nezbro

a guest
May 14th, 2015
247
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.76 KB | None | 0 0
  1. local monitor = peripheral.wrap("top")
  2. monitor.clear()
  3. while true do
  4.   while rs.getInput ("front")
  5.    and  rs.getInput ("back")
  6.               == true do
  7.   monitor.setTextScale(2)
  8.   monitor.setCursorPos(11,3)
  9.   monitor.write("Hello")
  10.   sleep(5)
  11.   monitor.clear()  
  12. end    
  13.   while rs.getInput ("front",true) do
  14.   monitor.setTextScale(2)
  15.   monitor.setCursorPos(11,3)
  16.   monitor.write("Front")
  17.   sleep(5)
  18.   monitor.clear()
  19. end
  20.   while rs.getInput ("back",true) do
  21.   monitor.setTextScale(2)
  22.   monitor.setCursorPos(11,3)
  23.   monitor.write("Back")
  24.   sleep(5)
  25.   monitor.clear()
  26. end
  27.   if not rs.getInput("front","back") then
  28.   monitor.setTextScale(2)
  29.   monitor.setCursorPos(9,3)
  30.   monitor.write("No Signal")
  31.   sleep (5)
  32.   monitor.clear()  
  33. end
  34. end
Advertisement
Add Comment
Please, Sign In to add comment