Guest User

startup

a guest
Aug 16th, 2014
301
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.51 KB | None | 0 0
  1. print('Monitoring Power Levels!')
  2.  
  3. --vars--
  4. cube = peripheral.wrap('cofh_thermalexpansion_energycell_1')
  5. energy = cube.getEnergyStored('right')
  6. monitor = peripheral.wrap('top')
  7.  
  8. monitor.setTextScale(1)
  9. monitor.setBackgroundColor(colors.black)
  10.  
  11. --main--
  12. while true do
  13.   monitor.clear()
  14.  
  15.   monitor.setCursorPos(1,1)
  16.   monitor.setTextColor(colors.white)
  17.   monitor.write('StorageBuffer #1')
  18.  
  19.   monitor.setCursorPos(1,2)
  20.   monitor.setTextColor(colors.red)
  21.   monitor.write(energy)
  22.    
  23.   sleep(1)
  24. end
Advertisement
Add Comment
Please, Sign In to add comment