protected void LoginResult(byte type, List<byte> data)
{
UInt32 result = BitConverter.ToUInt32(data.ToArray(), 4);
switch(result)
{
case 0x00:
if (ClientlessBot.debugging) Console.WriteLine("{0}: [BNCS] Successfully logged into the account ", m_owner.Account);
break;
case 0x01:
Console.WriteLine("{0}: [BNCS] Account does not exist", m_owner.Account);
break;
case 0x02:
Console.WriteLine("{0}: [BNCS] Invalid password specified" , m_owner.Account);
break;
case 0x06:
Console.WriteLine("{0}: [BNCS] Account has been closed" , m_owner.Account);
break;
default:
Console.WriteLine("{0}: [BNCS] Unknown login error ({1})", m_owner.Account,result);
break;
}
if (result == 0)
{
if (ClientlessBot.debugging)
Console.WriteLine("{0}: [BNCS] Requesting Realm List", m_owner.Account);
byte[] packet = { 0xFF, 0x40, 0x04, 0x00 };
m_stream.Write(packet, 0, 4);
}
else
return;
}