Newbie Spellweaver
- Joined
- May 21, 2007
- Messages
- 81
- Reaction score
- 1
Knight Online, like most client/server software (but not all; for example, IRC clients all use the same protocol - IRC's!), uses it's own packet structure or protocol.
A (short) Knight Online packet might look like this (hex string form - AA == 0xAA):
Lets make it easier to read.
That's better.
The first thing you should make a note of, is that the packet starts with AA 55, and ends with 55 AA. You will find that this is common with all Knight Online packets.
These are, in respective order, our packet header and packet tail. They serve no other purpose than to indicate the start and end of a packet.
This is our example packet so far.
Now, the next byte in the packet (directly after AA55), is 01. 01 in decimal form, is "1". Well, that part was obvious, anyway. I wonder what this part is for? It's hard to tell.. so, let's compare it to another packet:
That's a much larger packet! 29 whole bytes!
Hmm, this makes little sense. It's all in hex form... maybe we should try converting it to ASCII form, that may just give us a hint.
To do this, (although slow), we can use the Windows calculator! (start->run->calc).
However, by default, we cannot use hexadecimal.. as we are running in "Standard" mode. Easy to change, just click the "View" menu, and select "Scientific".
Make sure "Hex" is selected, then type in the first: 15.
To convert it to decimal, now select "Dec". You'll see that "15" was replaced with... 21! This is our ASCII key code. From there, it's a simple hop, skip and a jump to our ASCII key. If you're unfamiliar with the ASCII key codes, a helpful resource is
A (short) Knight Online packet might look like this (hex string form - AA == 0xAA):
Code:
AA5501000155AA
Lets make it easier to read.
Code:
AA
55
01
00
01
55
AA
The first thing you should make a note of, is that the packet starts with AA 55, and ends with 55 AA. You will find that this is common with all Knight Online packets.
These are, in respective order, our packet header and packet tail. They serve no other purpose than to indicate the start and end of a packet.
Code:
AA 55 (packet header)
01
00
01
55 AA (packet tail)
Now, the next byte in the packet (directly after AA55), is 01. 01 in decimal form, is "1". Well, that part was obvious, anyway. I wonder what this part is for? It's hard to tell.. so, let's compare it to another packet:
Code:
AA 55 (packet header)
15
00
F3
08
00
74
77
6F
73
74
61
72
73
08
00
70
61
73
73
77
6F
72
64
55 AA (packet tail)
Hmm, this makes little sense. It's all in hex form... maybe we should try converting it to ASCII form, that may just give us a hint.
To do this, (although slow), we can use the Windows calculator! (start->run->calc).
However, by default, we cannot use hexadecimal.. as we are running in "Standard" mode. Easy to change, just click the "View" menu, and select "Scientific".
Make sure "Hex" is selected, then type in the first: 15.
To convert it to decimal, now select "Dec". You'll see that "15" was replaced with... 21! This is our ASCII key code. From there, it's a simple hop, skip and a jump to our ASCII key. If you're unfamiliar with the ASCII key codes, a helpful resource is
You must be registered to see links
. Plain and simple, and to the point. No pictures; you can use your browser's "Find/Search" function to skip straight to your key.
Code:
AA 55 (packet header)
hex = decimal (ASCII key code) = character
15 = 21 = 1
00 = 0 = <NULL>
F3 = 243 =