示例#1
0
 public override void Start()
 {
     host = platform.EnetCreateHost();
     platform.EnetHostInitialize(host, null, 1, 0, 0, 0);
     tosend   = new QueueINetOutgoingMessage();
     messages = new QueueNetIncomingMessage();
 }
示例#2
0
 public override void Start()
 {
     host = new EnetHostNative()
     {
         host = new ENet.Host()
     };
     ((EnetHostNative)host).host.InitializeServer(Port, 256);
 }
示例#3
0
 public abstract void EnetHostInitializeServer(EnetHost host, int port, int peerLimit);
示例#4
0
 public abstract bool EnetHostService(EnetHost host, int timeout, EnetEventRef enetEvent);
示例#5
0
 public abstract void EnetHostInitializeServer(EnetHost host, int port, int peerLimit);
示例#6
0
 public abstract void EnetHostInitialize(EnetHost host, IPEndPointCi address, int peerLimit, int channelLimit, int incomingBandwidth, int outgoingBandwidth);
示例#7
0
 public abstract EnetPeer EnetHostConnect(EnetHost host, string hostName, int port, int data, int channelLimit);
示例#8
0
 public override EnetPeer EnetHostConnect(EnetHost host, string hostName, int port, int data, int channelLimit)
 {
     EnetHostNative host_ = (EnetHostNative)host;
     ENet.Peer peer = host_.host.Connect(hostName, port, data, channelLimit);
     EnetPeerNative peer_ = new EnetPeerNative();
     peer_.peer = peer;
     return peer_;
 }
示例#9
0
 public abstract EnetPeer EnetHostConnect(EnetHost host, string hostName, int port, int data, int channelLimit);
示例#10
0
 public override void Start()
 {
     host = platform.EnetCreateHost();
     platform.EnetHostInitialize(host, null, 1, 0, 0, 0);
     tosend = new QueueINetOutgoingMessage();
     messages = new QueueNetIncomingMessage();
 }
示例#11
0
 public override void Start()
 {
     host = platform.EnetCreateHost();
     platform.EnetHostInitializeServer(host, Port, 256);
 }
示例#12
0
 public override bool EnetHostService(EnetHost host, int timeout, EnetEventRef enetEvent)
 {
     EnetHostNative host_ = (EnetHostNative)host;
     ENet.Event e;
     bool ret = host_.host.Service(timeout, out e);
     EnetEventNative ee = new EnetEventNative();
     ee.e = e;
     enetEvent.e = ee;
     return ret;
 }
示例#13
0
 public override void EnetHostInitializeServer(EnetHost host, int port, int peerLimit)
 {
     EnetHostNative host_ = (EnetHostNative)host;
     host_.host.InitializeServer(port, peerLimit);
 }
示例#14
0
 public override void EnetHostInitialize(EnetHost host, IPEndPointCi address, int peerLimit, int channelLimit, int incomingBandwidth, int outgoingBandwidth)
 {
     if (address != null)
     {
         throw new Exception();
     }
     EnetHostNative host_ = (EnetHostNative)host;
     host_.host.Initialize(null, peerLimit, channelLimit, incomingBandwidth, outgoingBandwidth);
 }
示例#15
0
 public abstract bool EnetHostService(EnetHost host, int timeout, EnetEventRef enetEvent);
示例#16
0
 public abstract bool EnetHostCheckEvents(EnetHost host, EnetEventRef event_);
示例#17
0
 public abstract bool EnetHostCheckEvents(EnetHost host, EnetEventRef event_);
示例#18
0
 public abstract void EnetHostInitialize(EnetHost host, IPEndPointCi address, int peerLimit, int channelLimit, int incomingBandwidth, int outgoingBandwidth);
示例#19
0
 public override bool EnetHostCheckEvents(EnetHost host, EnetEventRef event_)
 {
     EnetHostNative host_ = (EnetHostNative)host;
     ENet.Event e;
     bool ret = host_.host.CheckEvents(out e);
     EnetEventNative ee = new EnetEventNative();
     ee.e = e;
     event_.e = ee;
     return ret;
 }