Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- password = 'password'
- firstDoor = colors.orange
- secondDoor = colors.red
- side = 'back'
- errorMessage = 'Failed'
- delay = 5
- currentlyOpen = 0;
- while true do
- term.clear()
- term.setCursorPos(1,1)
- write('Password: ')
- input = read('*')
- if input == password then
- rs.setBundledOutput(side, firstDoor)
- sleep(delay)
- rs.setBundledOutput(side, 0)
- sleep(delay / 2)
- rs.setBundledOutput(side, secondDoor)
- sleep(5)
- rs.setBundledOutput(side, 0)
- else
- term.clear()
- term.setCursorPos(1,1)
- print(errorMessage)
- sleep(1)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement