MattTuttle / hxnet

Networking library for Haxe (UDP, TCP, RPC, Telnet, WebSocket)
95 stars 9 forks source link

Udp support seems to be out of date? #12

Open jscott1989 opened 8 years ago

jscott1989 commented 8 years ago

Trying to set up a Udp server, using:

import hxnet.base.Factory; import hxnet.udp.Server;

var server = new Server(new Factory(hxnet.protocols.Telnet), 5959, "localhost");

I get the errors:

/usr/local/lib/haxelib/hxnet/git/hxnet/udp/Server.hx:72: characters 5-28 : hxnet.interfaces.Protocol has no field makeConnection (Suggestion: loseConnection) /usr/local/lib/haxelib/hxnet/git/hxnet/udp/Connection.hx:10: lines 10-49 : Field isOpen needed by hxnet.interfaces.Connection is missing /usr/local/lib/haxelib/hxnet/git/hxnet/udp/Connection.hx:18: lines 18-40 : Field writeBytes has different type than in hxnet.interfaces.Connection /usr/local/lib/haxelib/hxnet/git/hxnet/udp/Connection.hx:18: lines 18-40 : Different number of function arguments /usr/local/lib/haxelib/hxnet/git/hxnet/udp/Server.hx:19: lines 19-97 : Field broadcast needed by hxnet.interfaces.Server is missing

Is it just that the udp classes haven't kept up to date and are no longer usable?

MattTuttle commented 8 years ago

Technically UDP was never officially added to Haxe. It was planned for a release in Neko but it had to be compiled from source. They haven't done a binary release of Neko since 2013 so https://github.com/HaxeFoundation/neko is your best bet.