How can I open every modem side using a table?
Auto Open Modem?
Started by 3ydney, Jan 22 2013 06:21 PM
2 replies to this topic
#1
Posted 22 January 2013 - 06:21 PM
#2
Posted 22 January 2013 - 06:23 PM
This uses the function getSides in the redstone (rs) API which returns a table of the sides... it then iterates through and using the peripheral API checks to see if the peripheral is a modem, if it is open the modem...
for _,v in pairs( rs.getSides() ) do if peripheral.getType( v ) == "modem" then rednet.open( v ) end end
#3
Posted 22 January 2013 - 06:25 PM
Thanks SO much... I was just about to try that!
2 user(s) are reading this topic
0 members, 2 guests, 0 anonymous users











