|
if i wasent wrong and you meant the current patch when you said (latest clients)
than yes there is something that should work as a key (loginkey),
for me im doing it almost like this ,
uint LoginKey = (uint)Rand.Next(1, 999999);
or
public static uint loginkey = 1;
where ever you have the uint.loginkey++;
and connect the logingkey to the client somehow idk something like Client.LoginKey = LoginKey ;
add the client to some dictionary
Dictionary<uint, Client> AuthorizedClients = new Dictionary<uint, Client>();
AuthorizedClients.Add(Client.UID, Client);
or maybe a list<Client> AuthorizedClients = new list<Client>();
AuthorizedClients.Add(Client);
and send the AuthResponse Packet with the client loginkey added
the offset is 8 thats where the key goes
uint(loginkey, 8);
and on loginseeq (case 1052) poll the player from the dictionary using the loginkey cus the client well respond with the login key you sent not with the client uid
uint key = (uint)BitConverter.ToUInt32(Data, 4);
uint loginkey = 0;
Character Client = new character()
foreach(in the AuthorizedClients or in the list )
{
if (key == Member.Value.LoginKey)
{
LoginKey = Member.Value.LoginKey;
Client = Member.Value;
break;
}
}
process the Client
**** that looks so **** Missie :S
and remember that sending the client uid rather than a random key/++`ed key is not gonna work cus if you logout and try to login again the client well respond with an error message cus the login key is the same (like you are still loged in) ,
and that was just one way you can do it cus there is alot more ways you can handle it
Good luck ,
|