On my program for Computer craft that will be used in a control tower in my airport map, I got a message that looked like this:
bios:367:[string "AirportCommand"]:15: syntax error
Here is all my code please tell me if you see any errors:
local Landing_open = true
rednet.open("top")
while true do
id, message, distance = rednet.receive()
if message == "Requesting Landing" and Landing_open == true and distance<500 then
rednet.send(id, "Landing is granted. Please respond with Landing finished when you exit the runway.")
Landing_open = false
elseif message == "Requesting Landing" and distance>=500 then
rednet,send(id, "Landing is not granted. Please try again when you are closer to the airport,")
elseif message == "Requesting Landing" and Landing_open == false then
rednet.send(id, "Landing is not granted. Please try again later.")
elseif message == "Landing Finished" then
rednet.send(id, "Roger that")
Landing_open = true
See Question&Answers more detail:os