public override void Connect(ConoConnect connect)
        {
            LobbyOwner owner = new LobbyOwner(connect);

            owner.Connect = connect;
            connect.SetOwner(owner);

            FrontLobbyPacket.ConnectResPacket packet = new FrontLobbyPacket.ConnectResPacket();
            packet.serverNo  = FrontManager.Instance.OwnerNo;
            packet.sessionId = "0";

            byte[] data = FrontLobbyPacket.Serialize(packet);

            connect.Send(data, data.Length);
        }
Exemplo n.º 2
0
        public void Process(IConoConnect connect, Packet packet)
        {
            FrontLobbyPacket.ConnectReqPacket crPacket = (FrontLobbyPacket.ConnectReqPacket)packet;

            long   serverNo  = crPacket.serverNo;
            string sessionId = crPacket.sessionId;
            string ip        = crPacket.clientIp;
            int    port      = crPacket.clientPort;

            LobbyOwner owner = (LobbyOwner)connect.GetOwner();

            owner.ClientIp   = ip;
            owner.ClientPort = port;

            FrontManager.Instance.GetOwnerManager((int)NETWORK_MODULE.NETWORK_MODULE_LOBBY).AddConnectOwner(serverNo, owner);
        }