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

LuaSocket?

Started by Noodle, 02 August 2012 - 10:36 AM
Noodle #1
Posted 02 August 2012 - 12:36 PM
This is actually not a "proper" coding question (which is why its in general), but is it possible to use luasocket?
Any examples if so?

I understand if rednet is the actual luasocket for the CC and the only possible to use..
MysticT #2
Posted 02 August 2012 - 06:36 PM
If you mean the luasocket library, you can't, since it's a c library. You could create some kind of sockets that work through rednet, but not actual sockets.
Noodle #3
Posted 02 August 2012 - 07:18 PM
I see but there isn't any way to implement this?
BigSHinyToys #4
Posted 02 August 2012 - 07:25 PM
I see but there isn't any way to implement this?
?? = confused
Basically make a program that adds a Header to the string you are sending. The header is a known length to make decoding it easer. and could contain a socket Number or port Number as well as other data ect..
PixelToast #5
Posted 03 August 2012 - 10:20 PM
done,
http://pastebin.com/XJ2298E4
Noodle #6
Posted 06 August 2012 - 06:54 AM
I wanted more of actual luasocket
Using actual luasocket meant that you could access other UDP/TCP connection outside of game.