Posted 01 November 2012 - 07:22 PM
I am making a multi door locking system and have ran it to a slite error when runing it says expected <eof>
Code
Code
Spoiler
os.pullEvent = os.pullEventRaw
term.clear()
term.setCursorPos(1,1)
local side = "bottom"
local num1 = "1"
local pass1 = "opendoor1"
local num2 = "2"
local pass2 = "opendoor2"
local num3 = "3"
local pass3 = "opendoor3"
local num4 = "4"
local pass4 = "opendoor4"
local num5 = "5"
local pass5 = "opendoor5"
local num6 = "6"
local pass6 = "opendoor6"
local num7 = "7"
local pass7 = "opendoor7"
local num8 = "8"
local pass8 = "opendoor8"
local num9 = "9"
local pass9 = "opendoor9"
local passwordadmin = "evolution"
print("Welcome to Evolution-Labs")
print("Please Enter a Door Id Number")
print("=1=2=3=4=5=6=7=8=9=")
write("Number: ")
local input = read("*")
if input == num1 then
print("Enter Door Password")
write ("Password: ")
if input == pass1 then
rs.setBundledOutput("side", colors.red)
sleep(3)
shell.run ("reboot")
end
end
if input == num2 then
print("Enter Door Password")
write ("Password: ")
if input == pass2 then
rs.setBundledOutput("side", colors.green)
sleep(3)
shell.run ("reboot")
end
end
if input == num3 then
print("Enter Door Password")
write ("Password: ")
if input == pass3 then
rs.setBundledOutput("side", colors.blue)
sleep(3)
shell.run ("reboot")
end
end
if input == num4 then
print("Enter Door Password")
write ("Password: ")
if input == pass4 then
rs.setBundledOutput("side", colors.yellow)
sleep(3)
shell.run ("reboot")
end
end
if input == num5 then
print("Enter Door Password")
write ("Password: ")
if input == pass5 then
rs.setBundledOutput("side", colors.lime)
sleep(3)
shell.run ("reboot")
end
end
if input == num6 then
print("Enter Door Password")
write ("Password: ")
if input == pass6 then
rs.setBundledOutput("side", colors.white)
sleep(3)
shell.run ("reboot")
end
end
if input == num7 then
print("Enter Door Password")
write ("Password: ")
if input == pass7 then
rs.setBundledOutput("side", colors.pink)
sleep(3)
shell.run ("reboot")
end
end
if input == num8 then
print("Enter Door Password")
write ("Password: ")
if input == pass8 then
rs.setBundledOutput("side", colors.black)
sleep(3)
shell.run ("reboot")
end
end
if input == num9 then
print("Enter Door Password")
write ("Password: ")
if input == pass9 then
rs.setBundledOutput("side", colors.brown)
sleep(3)
shell.run ("reboot")
end
end
if input == passwordadmin then
term.clear()
term.setCursorPos(1,1)
print("Admin overide!")
print("Computer unlocking...")
print("Please shutdown the console before leaving")
os.pullEvent(terminate)
end
end
else
print("Good Bye!")
sleep(3)
os.reboot