Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- os.loadAPI("button")--pastebin get 1iwuzsh8 button--and edit the side of monitor
- mon = peripheral.wrap("right")--Set Side Of Monitor
- mon.clear()
- function fillTable()-- Add "button.setTable("{name}", {f-name},{xmin},{xmax},{ymin},{ymax})--this starts the button
- button.setTable("ReplicatorOnly", replicatoronly,5,23,3,5)--example
- button.setTable("MassOnly", massonly,5,23,7,9)
- button.setTable("ScannerOnly", scanneronly,5,23,11,13)
- button.setTable("RepAndReac", repandreac,28,46,3,5)
- button.setTable("MassAndReac", massandreac,28,46,7,9)
- button.setTable("ScanAndReac", scanandreac,28,46,11,13)
- button.setTable("ReactorOnly", reactoronly,5,23,15,17)
- button.setTable("Reset", reset,28,46,15,17)
- button.screen()
- end
- function getClick()--This do not edit [checks monitor for touch]
- event,side,x,y = os.pullEvent("monitor_touch")
- button.checkxy(x,y)
- end
- --Add function {name from top}()-- new button
- --Then Add what you want is to do
- --Finally end()
- function replicatoronly()--example
- button.flash("ReplicatorOnly")
- rs.setBundledOutput("left",1)
- rs.setBundledOutput("bottom",0)
- end
- function massonly()
- button.flash("MassOnly")
- rs.setBundledOutput("left",2)
- rs.setBundledOutput("bottom",0)
- end
- function scanneronly()
- button.flash("ScannerOnly")
- rs.setBundledOutput("left",4)
- rs.setBundledOutput("bottom",0)
- end
- function repandreac()
- button.flash("RepAndReac")
- rs.setBundledOutput("left",1)
- rs.setBundledOutput("bottom",8)
- end
- function massandreac()
- button.flash("MassAndReac")
- rs.setBundledOutput("left",2)
- rs.setBundledOutput("bottom",8)
- end
- function scanandreac()
- button.flash("ScanAndReac")
- rs.setBundledOutput("left",4)
- rs.setBundledOutput("bottom",8)
- end
- function reactoronly()
- button.flash("ReactorOnly")
- rs.setBundledOutput("left",0)
- rs.setBundledOutput("bottom",8)
- end
- function reset()
- button.flash("Reset")
- rs.setBundledOutput("left",0)
- rs.setBundledOutput("bottom",0)
- end
- fillTable()
- button.heading("ThunderBadge's UU Matter Factory")--name on top
- while true do--loop
- getClick()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement