Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- tID = 90 -- ID de la turtle a controler
- --m = peripheral.wrap("right")
- p = peripheral.wrap("left")
- function getStoredPercent()
- -- print(textutils.serialize(p.getMethodsRemote("MFFSCapacitor_0")))
- percent_ = p.callRemote("MFFSCapacitor_0", "getStoredForceEnergy")
- return (percent_/100000)
- end
- if not rednet.isOpen("right") then
- rednet.open("right")
- end
- sleep(2)
- while true do
- while getStoredPercent() <= 16 do
- sleep(5)
- end
- rednet.send(tID, "place_base")
- while true do
- id, message = rednet.receive()
- if id == tID then
- if message == "place_done" then
- break
- end
- end
- end
- redstone.setOutput("front", true)
- rednet.send(tID, "place_head")
- while true do
- id, message = rednet.receive()
- if id == tID then
- if message == "disable_mffs" then
- redstone.setOutput("front", false)
- end
- if message == "star_picked" then
- break
- end
- end
- end
- sleep(1)
- end
Advertisement
Add Comment
Please, Sign In to add comment