JaMaNi133

CC Reactor Monitor

Jul 7th, 2021 (edited)
161
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.01 KB | None | 0 0
  1. -- pastebin get FWFLeJG1 reactor.lua
  2.  
  3. reactor = peripheral.wrap("Bigreactors-Reactor_0")
  4. display = peripheral.wrap("monitor_0")
  5.  
  6. while true do
  7.  
  8.     local tevent, tperipheral_name, tx, ty = os.pullEvent("monitor_touch")
  9.     if peripheral_name == display then
  10.  
  11.     end
  12.     --display.setTextSize(3)
  13.     display.clear()
  14.     display.setCursorPos(1,10)
  15.     display.write(string.format("Fuel Left : %d mb / %d mb",reactor.getFuelAmount(),reactor.getFuelAmountMax()))
  16.     display.setCursorPos(1,9)
  17.     display.write(string.format("Generated RF/Tick : %d RF/t",reactor.getEnergyProducedLastTick()))
  18.     display.setCursorPos(1,8)
  19.     display.write(string.format("Casing Temperature : %d °C",reactor.getTemperature()))
  20.     display.setCursorPos(1,7)
  21.     display.write(string.format("Core Temperature : %d °C",reactor.getFuelTemperature()))
  22.     display.setCursorPos(1,6)
  23.     display.write(string.format("Fuel Reactivity : %d %d",reactor.getFuelReactivity(),"%"))
  24.     display.setCursorPos(1,5)
  25.     display.write(string.format("Stored RF : %d RF",reactor.getEnergyStored()))
  26. end
Add Comment
Please, Sign In to add comment