Esempio n. 1
0
        protected internal override void Read()
        {
            serverId = ReadD();
            string serverName = ReadS();
            string serverAddr = ReadS();
            bool useAkey = (ReadC() == 1) ? true : false;
            ServerStruct server = new ServerStruct(serverId, serverName, serverAddr, useAkey);

            int channel_count = ReadD();
            for(int i = 0; i < channel_count; i++)
            {
                int id = ReadH();
                string name = ReadS();
                int port = ReadH();
                int type = ReadC();
                int max = ReadD();
                int curr = ReadD();
                ChannelStruct channel = new ChannelStruct(id, name, port, type, max, curr);
                server.Channels.Add(channel.Id, channel);
            }

            LoginServer.ServerList.Add(server.Id, server);
        }
Esempio n. 2
0
        protected internal override void Read()
        {
            serverId = ReadD();
            string       serverName = ReadS();
            string       serverAddr = ReadS();
            bool         useAkey    = (ReadC() == 1) ? true : false;
            ServerStruct server     = new ServerStruct(serverId, serverName, serverAddr, useAkey);

            int channel_count = ReadD();

            for (int i = 0; i < channel_count; i++)
            {
                int           id      = ReadH();
                string        name    = ReadS();
                int           port    = ReadH();
                int           type    = ReadC();
                int           max     = ReadD();
                int           curr    = ReadD();
                ChannelStruct channel = new ChannelStruct(id, name, port, type, max, curr);
                server.Channels.Add(channel.Id, channel);
            }

            LoginServer.ServerList.Add(server.Id, server);
        }
Esempio n. 3
0
 public ResponseSelectServer(int sid, int cid)
 {
     server  = LoginServer.ServerList[sid];
     channel = server.Channels[cid];
 }
Esempio n. 4
0
 public ResponseSelectServer(int sid, int cid)
 {
     server = LoginServer.ServerList[sid];
     channel = server.Channels[cid];
 }