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

Rednet help

Started by graywolf69, 04 February 2015 - 02:56 PM
graywolf69 #1
Posted 04 February 2015 - 03:56 PM
I'm trying to get a wireless missile launching program going. I haven't done rednet in a while and just my luck, I didn't get it right. None of the redstone signals activate and I'm guessing I am sending the message wrong. Heres my sending program and my receiving program, thanks for the help!!!

Sending: http://pastebin.com/F0j9TugB

Receiving: http://pastebin.com/XTxByEq1
KingFlix #2
Posted 04 February 2015 - 04:16 PM
When comparing your input in the sending script you compare with a variable and not a string. Just put the words in quotation marks (e.g. [ if input=="launch1" then ] instead of [ if input==launch1 then ] )
Edited on 04 February 2015 - 03:16 PM
TR1T0N_ #3
Posted 04 February 2015 - 04:18 PM
i believe your problem lies within your if functions. Because when you get your input from function "i2" you then compare it to launch1 which doesnt have quotation marks and is trying to compare it to a variable which doesn't exist so if you add quotation marks to each side of launch1,2,3,4 and all it should work also on the receive function i dont think you put the brackets around what you are comparing it too so it should be
if id == 9 or id == 10 then instead of if id == (9) or id == (10) then (line 10 receive program) –cant remember if this makes a difference.
also make sure both computers are with range,
here is just a list of what could be wrong and i hope i could help
Edited on 04 February 2015 - 03:19 PM
graywolf69 #4
Posted 04 February 2015 - 06:24 PM
Thanks, this makes sense so hopefully will work when I get home!

EDIT: Yes it worked, thanks!
Edited on 05 February 2015 - 02:27 PM