Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local uid = 13
- rednet.open("top")
- -- tuer
- local pass = "passwort"
- local close = "zu"
- local id, mess = rednet.receive()
- if id == uid and mess == pass then
- redstone.setOutput("right", true)
- rednet.send(id, "die Tuer ist nun offen!")
- local b = 1
- while b == 1 do
- id, mess = rednet.receive()
- if id == uid and mess == close then
- b = 0
- redstone.setOutput("right", false)
- rednet.send(id, "1")
- elseif mess ~= close then
- rednet.send(id, "2")
- end
- end
- elseif id ~= uid then
- rednet.send(id, "Sie haben nicht die Befugnis!")
- else
- rednet.send(id,"falsches Passwort")
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement