Post your best Lua script examples here

User avatar
By luiscolo
#80787 Hi to everyone!
i am trying to send a simple udp packet, something like this:

sk = net.createUDPSocket()
sk:send(6000,"255.255.255.255",'data')

it works perfect inside an :on "receive" block but i can't find the way to simply send an udp packet without another received, i know i am missing something, but i don't know what,

does anybody knows how to simply send an udp packet without another udp received, it means, not inside an :on "receive" block?

thank you in advance,
Luis