Posted 11 July 2015 - 11:58 PM
Hello. I've started making a nuclear reactor control program on a computer. I've set the reactor up and started working on the computer, however, the flush program doesn't work. Can anyone help? The second part works but the pulse i've made doesn't. In some cases it pulses once or twice and then just stops. Here's the code:
local function addcol(colour, side)
rs.setBundledOutput(side, colours.combine(rs.getBundledOutput(side),col))
end
local function remcol(colour, side)
rs.setBundledOutput(side, colours.subtract(rs.getBundledOutput(side),col))
term.clear()
print("Flushing...")
while rs.testBundledInput("back", colours.red) do
rs.setBundledOutput("back", colours.blue)
sleep(1)
remcol(colours.blue, 'back')
end
end
while rs.testBundledInput("back", colours.red) do
rs.setBundledOutput("back", colours.magenta)
sleep(80)
os.reboot()
end