Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- rednet.open("top")
- -- tuer
- local sid = 14
- local m = "a"
- print("Was ergibt 3 x 3?\n")
- m = io.read()
- rednet.send(sid, m)
- id = 1
- while id ~= sid do
- id, m = rednet.receive()
- end
- print(m)
- local o = "2"
- if m == "die Tuer ist nun offen!" then
- while o == "2" do
- print("Schliessen Sie die Tuer!")
- print("Geben Sie dazu zu ein!\n")
- m = io.read()
- rednet.send(sid, m)
- id, o = rednet.receive()
- if id == sid and o == "1" then
- print("Die Tuer wurde geschlossen")
- sleep(2)
- elseif o == "2" then
- print("falsches Wort\n\n")
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement