jonassvensson4

Untitled

Jun 7th, 2013
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.45 KB | None | 0 0
  1. local cable_side = "back"
  2. local cable_color = colors.white
  3.  
  4. function RunStuff()
  5. side = "top"
  6. text = "Welcome to Jonas mansion!"
  7.     mon = peripheral.wrap(side)
  8.     mon.setTextScale(2)
  9.     mon.setCursorPos(4,5)
  10.     mon.write(text)
  11. end
  12.  
  13. function ListenRedstone()
  14.     while true end
  15.         local state = colors.test( redstone.getBundledInput( cable_side ), cable_color )
  16.        
  17.         if ( state ) then
  18.             RunStuff()
  19.         end
  20.        
  21.         sleep( 0.2 )
  22.     end
  23. end
  24.  
  25. ListenRedstone()
Advertisement
Add Comment
Please, Sign In to add comment