Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local mainId = 1
- local stationName = "Oak"
- while true do
- rednet.open("top")
- id1,msg1 = rednet.receive()
- rednet.send(mainId,msg1 .. "-1")
- id2,msg2 = rednet.receive()
- if id2 == mainId then
- if msg2 == "ok" then
- rednet.send(mainId,msg1 .. "-2")
- id3,msg3 = rednet.receive()
- rednet.send(id1,"Bienvenue à :" .. stationName)
- redstone.setOutput("left",true)
- os.sleep(0.5)
- redstone.setOutput("left",false)
- else
- rednet.send(id1,"Tu n'as plus de tickets")
- end
- else
- rednet.send(id1,"Une erreur c'est produite")
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement