protected override void Format57Handler(LoginClient client, ClientFormat57 format) { if (format.Type == 0x00) { var redirect = new Redirect { Serial = client.Serial, Salt = client.Encryption.Parameters.Salt, Seed = client.Encryption.Parameters.Seed, Name = "socket[" + client.Serial + "]" }; ServerContext.GlobalRedirects.Add(redirect); client.Send(new ServerFormat03 { EndPoint = new IPEndPoint(Address, 2610), Redirect = redirect }); } if (format.Type == 0x01) { client.Send(new ServerFormat56 { Size = MServerTable.Size, Data = MServerTable.Data }); } }
protected override void Format57Handler(LoginClient client, ClientFormat57 format) { if (format.Type == 0x00) { var redirect = new Redirect { Serial = Convert.ToString(client.Serial), Salt = Encoding.UTF8.GetString(client.Encryption.Parameters.Salt), Seed = Convert.ToString(client.Encryption.Parameters.Seed), Name = "socket[" + client.Serial + "]" }; client.Send(new ServerFormat03 { EndPoint = new IPEndPoint(MServerTable.Servers[0].Address, MServerTable.Servers[0].Port), Redirect = redirect }); } else { client.Send(new ServerFormat56 { Size = MServerTable.Size, Data = MServerTable.Data }); } }
protected virtual void Format57Handler(TClient client, ClientFormat57 format) { }