Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- pass = "age368RG"
- term.clear()
- term.setCursorPos(1,1)
- print("ID Card Reader")
- local reader = peripheral.wrap("top")
- while true do
- local event,arg1,arg2,arg3 = os.pullEvent()
- if event == "mag_swipe" then
- print("Card Swiped.")
- if arg1 == pass then
- print("Access Granted.")
- rs.setOutput("right", true)
- sleep(3)
- os.reboot()
- else
- print("Access Denied.")
- reader.setInsertCardLight(true)
- sleep(1.5)
- reader.setInsertCardLight(false)
- os.reboot()
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement