3 posts
Posted 26 July 2012 - 04:11 AM
Hi. I have a computer that constantly outputs a redstone signal right. Is there a way to make it stop outputting right if it recieves a signal from the bottom?
current code
print ("Enter Password")
redstone.setOutput ("right", true)
I would like for it to stop output right when it recieves input from the bottom, thanks.
109 posts
Posted 26 July 2012 - 06:02 AM
Yes actually.
You would have it do this…
print ("Enter Password")
while noBottomRed do
redstone.setOutput ("right", true)
if rs.getInput('bottom') then
noBottomRed == false
end--end if
end--end while
--rest of your code
3 posts
Posted 29 July 2012 - 08:08 PM
Thanks. I'm brand new so I have no idea what I'm doing.
Thanks for your time.
3 posts
Posted 30 July 2012 - 09:54 PM
It gives me an Error.
bios:206: [string "startup"]"5" '=' expected
167 posts
Posted 30 July 2012 - 09:59 PM
It gives me an Error.
bios:206: [string "startup"]"5" '=' expected
Just change the == at line 5 to an =
1604 posts
Posted 30 July 2012 - 10:12 PM
It should be:
rs.setOutput("right", true)
while not rs.getInput("bottom") do
os.pullEvent("redstone")
end