Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ::pin_enter::
- print("Please enter the correct PIN to unlock door.") -- Display text.
- local inputvar = term.read()
- term.write("pin| '"..pin.."', input='"..inputvar.."'")
- if inputvar == pin then -- If input is equal to the PIN, goto "correct"
- goto correct
- else
- print("Incorrect.") -- Display text.
- goto pin_enter -- Goto "pin_enter"
- end
- ::correct::
- print("Correct.")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement