Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- os.pullEvent = os.pullEventRaw
- x = 1
- while true do
- term.clear()
- term.setCursorPos(1,1)
- print("Please enter the correct password: ")
- local input = read("*")
- if input == "123" then
- term.clear()
- term.setCursorPos(1,1)
- textutils.slowWrite("The password entered was correct!")
- sleep(1)
- term.clear()
- term.setCursorPos(1,1)
- textutils.slowWrite("Opening Gate...")
- rs.setOutput("back",true)
- sleep(5)
- rs.setOutput("back",false)
- else if input == "1234" then
- term.clear()
- term.setCursorPos(1,1)
- textutils.slowWrite("Admin password has been entered.")
- sleep(1)
- term.clear()
- term.setCursorPos(1,1)
- textutils.slowPrint("One moment...")
- sleep(2)
- term.clear()
- term.setCursorPos(1,1)
- error()
- else if x == 4 then
- textutils.slowPrint("The password entered has been incorrect 4 times...")
- sleep(1)
- term.clear()
- term.setCursorPos(1,1)
- textutils.slowPrint("LOCK DOWN!")
- sleep(300)
- x = 1
- else
- term.clear()
- term.setCursorPos(1,1)
- textutils.slowPrint("The password entered was incorrect!")
- x = x + 1
- sleep(2)
- end
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment