rswiki-book/468-Protocol.mediawiki

53 lines
1.2 KiB
Plaintext
Raw Normal View History

2013-10-24 20:24:04 -04:00
[[Category RS2]]
Currently under development.
== '''Packet structure''' ==
When the client sends a packet to the server, the first byte encapsulates its opcode. This specific opcode is encrypted with a value generated by the ISAAC PRNG seeded with a dynamically server generated key during the login block. The server decrypts it and associates the opcode to the packet's respective predefined size. If the packet does not contain a fixed size, the opcode will be followed by either a byte or a word - varying per packet - for its proper size. This is then followed by the payload.
== '''Login''' ==
Blank at the moment.
=='''Game Protocol'''==
===Server -> Client Packets===
{| border=2
|-
! Opcode
! Type
! Length (bytes)
! Name
! Description
|-
2013-10-24 20:26:23 -04:00
| 147
| DataType.SHORT, DataOrder.LITTLE,
2013-10-24 20:24:04 -04:00
| 1
| [[317 Run Energy|Run Energy]]
2013-10-24 20:26:23 -04:00
| Sends the Mapregion
2013-10-24 20:24:04 -04:00
|-
|}
===Client -> Server Packets===
{| border=2
|-
! Opcode
! Type
! Length (bytes)
! Name
! Description
|-
| 49
| VARIABLE BYTE
| 13
| [[464 Character Design|Character Design]]
| Sent when accepting the player's appearance on the design screen.
|-
| 115
| VARIABLE BYTE
| N/A
| [[464 Chat|Chat]]
| Sent when the player enters a chat message.
|-
|}