Example #1
0
 public SFConnection(SFIMessageRouter messageRouter, ProtocolType protocolType = ProtocolType.MRUDP)
 {
     // Don't use constructor of SFObject, it will increase reference count of the object
     if (protocolType == ProtocolType.MRUDP)
     {
         NativeHandle = NativeCreateConnection();
     }
     else
     {
         NativeHandle = NativeCreateConnectionTCP();
     }
     m_MessageRouter = messageRouter;
 }
Example #2
0
 public OnlineClient(SFIMessageRouter messageRouter = null)
 {
     NativeHandle    = NativeCreateOnlineClient();
     m_MessageRouter = messageRouter;
 }
Example #3
0
 public SFConnection(IntPtr nativeHandle, SFIMessageRouter messageRouter = null)
 {
     // Don't use constructor of SFObject, it will increase reference count of the object
     NativeHandle    = nativeHandle;
     m_MessageRouter = messageRouter;
 }
Example #4
0
 public SFConnection(SFConnectionGroup group, SFIMessageRouter messageRouter)
 {
     // Don't use constructor of SFObject, it will increase reference count of the object
     NativeHandle    = NativeCreateConnectionWithGroup(group.NativeHandle);
     m_MessageRouter = messageRouter;
 }