This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
coolmark1995's profile picture

Topic Hijack Question

Started by coolmark1995, 05 October 2013 - 05:28 PM
coolmark1995 #1
Posted 05 October 2013 - 07:28 PM
Hello I know this topic is old but how could I use this code to stop a program on another computer as well?
rednet.open("top") set to wherever you got the modem
id
, message, distance = rednet.receive()
shell.run(message)
rednet.close()
Lyqyd #2
Posted 05 October 2013 - 07:44 PM
Split into new topic.

Don't hijack ancient topics to ask unrelated questions.
jay5476 #3
Posted 05 October 2013 - 09:35 PM
well yes that would work for the first message it receives loop it like so

rednet.open("top")
unreceived = true
while unreceived do
  id,mes,dis = rednet.receive()
  if fs.exists(mes) then
	unreceived = false
    shell.run(mes)
  end
end
rednet.close("top")