function clear()
term.clear()
term.setCursorPos(1,1)
end
clear()
print("please type in the password")
function lock()
os.pullEvent = os.pullEventRaw
end
local pass = 322221
term.setCursorPos(1,5)
write("password:")
input = read("*")
if pass == input then
print("Password correct!")
redstone.setOutput("top",true)
sleep(5)
redstone.setOutput("top",false)
shell.run("reboot")
else
print("password incorrect!")
shell.run("reboot")
end
and every time I run it, even if I type the right password, it just say password incorrect!
term.clear()
term.setCursorPos(1,1)
end
clear()
print("please type in the password")
function lock()
os.pullEvent = os.pullEventRaw
end
local pass = 322221
term.setCursorPos(1,5)
write("password:")
input = read("*")
if pass == input then
print("Password correct!")
redstone.setOutput("top",true)
sleep(5)
redstone.setOutput("top",false)
shell.run("reboot")
else
print("password incorrect!")
shell.run("reboot")
end
and every time I run it, even if I type the right password, it just say password incorrect!