Posted 01 January 2013 - 06:35 AM
Hello, im trying to get a hatch to open when i type "open" in the computer, but its not working at all.
I get "startup :9: attempt to call nil every time and i cant figure out what to do. The code is below
Oh, and am i doing it correct to get it to pulse 11 times on top? Thanks!
val1 = "open"
print("type open")
write "root: "
input = read()
if val1 == val1 then
redstone.setOutput("left",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
I get "startup :9: attempt to call nil every time and i cant figure out what to do. The code is below
Oh, and am i doing it correct to get it to pulse 11 times on top? Thanks!
val1 = "open"
print("type open")
write "root: "
input = read()
if val1 == val1 then
redstone.setOutput("left",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)
redstone.setOutput("top",true)
sleep(0.85)