Difference between revisions of "317 Protocol"

From RuneWiki
Jump to navigationJump to search
Line 195: Line 195:
 
| FIXED
 
| FIXED
 
| 0
 
| 0
| Idle
+
| [[317:Idle|Idle]]
 
| Sent when there are no actions being performed by the player for this cycle.
 
| Sent when there are no actions being performed by the player for this cycle.
 
|-
 
|-
Line 201: Line 201:
 
| FIXED
 
| FIXED
 
| 1
 
| 1
| Focus change
+
| [[317:Focus change|Focus change]]
 
| Sent when the game client window goes out of focus.
 
| Sent when the game client window goes out of focus.
 
|-
 
|-
Line 207: Line 207:
 
| VARIABLE BYTE
 
| VARIABLE BYTE
 
| N/A
 
| N/A
| Chat
+
| [[317:Chat|Chat]]
 
| Sent when the player enters a chat message.
 
| Sent when the player enters a chat message.
 
|-
 
|-
Line 213: Line 213:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Equip Item
+
| [[317:Equip item|Equip item]]
 
| Sent when a player equips an item.
 
| Sent when a player equips an item.
 
|-
 
|-
Line 219: Line 219:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Bank 10 items
+
| [[317:Bank 10 items|Bank 10 items]]
 
| Sent when a player banks 10 of a certain item.
 
| Sent when a player banks 10 of a certain item.
 
|-
 
|-
Line 225: Line 225:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Object action 3
+
| [[317:Object action 3|Object action 3]]
 
| Sent when the player clicks the third action available for an object.
 
| Sent when the player clicks the third action available for an object.
 
|-
 
|-
Line 231: Line 231:
 
| FIXED
 
| FIXED
 
| 2
 
| 2
| Trade request
+
| [[317:Trade request|Trade request]]
 
| Sent when a player requests a trade with another player.
 
| Sent when a player requests a trade with another player.
 
|-
 
|-
Line 237: Line 237:
 
| FIXED
 
| FIXED
 
| 4
 
| 4
| Camera movement
+
| [[317:Camera movement|Camera movement]]
 
| Sent when the player moves the camera.
 
| Sent when the player moves the camera.
 
|-
 
|-
Line 243: Line 243:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Drop item
+
| [[317:Drop item|Drop item]]
 
| Sent when a player wants to drop an item onto the ground.
 
| Sent when a player wants to drop an item onto the ground.
 
|-
 
|-
Line 249: Line 249:
 
| VARIABLE_BYTE
 
| VARIABLE_BYTE
 
| N/A
 
| N/A
| Walk on command
+
| [[317:Walk on command|Walk on command]]
 
| Sent when the player should walk somewhere according to a certain action performed, such as clicking an object.
 
| Sent when the player should walk somewhere according to a certain action performed, such as clicking an object.
 
|-
 
|-
Line 255: Line 255:
 
| VARIABLE_BYTE
 
| VARIABLE_BYTE
 
| N/A
 
| N/A
| Player command
+
| [[317:Player command|Player command]]
 
| Sent when the player enters a command in the chat box (i.e. "::command")
 
| Sent when the player enters a command in the chat box (i.e. "::command")
 
|-
 
|-
Line 261: Line 261:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Bank 5 items
+
| [[317:Bank 5 items|Bank 5 items]]
 
| Sent when a player banks 5 of a certain item.
 
| Sent when a player banks 5 of a certain item.
 
|-
 
|-
Line 267: Line 267:
 
| FIXED
 
| FIXED
 
| 0
 
| 0
| Loading finished
+
| [[317:Loading finished|Loading finished]]
 
| Sent when the client finishes loading a map region.
 
| Sent when the client finishes loading a map region.
 
|-
 
|-
Line 273: Line 273:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Item action 1
+
| [[317:Item action 1|Item action 1]]
 
| Sent when the player clicks the first option of an item, such as "Bury" for bones.
 
| Sent when the player clicks the first option of an item, such as "Bury" for bones.
 
|-
 
|-
Line 279: Line 279:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Bank all items
+
| [[317:Bank all items|Bank all items]]
 
| Sent when a player banks all of a certain item that they have in their inventory.
 
| Sent when a player banks all of a certain item that they have in their inventory.
 
|-
 
|-
Line 285: Line 285:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Object action 1
+
| [[317:Object action 1|Object action 1]]
 
| Sent when the player clicks the first option of an object, such as "Cut" for trees.
 
| Sent when the player clicks the first option of an object, such as "Cut" for trees.
 
|-
 
|-
Line 291: Line 291:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Bank X items part-1
+
| [[317:Bank X items part-1|Bank X items part-1]]
 
| Sent when a player requests to bank an X amount of items.
 
| Sent when a player requests to bank an X amount of items.
 
|-
 
|-
Line 297: Line 297:
 
| FIXED
 
| FIXED
 
| 2
 
| 2
| Trade answer
+
| [[317:Trade answer|Trade answer]]
 
| Sent when a player answers a trade request from another player.
 
| Sent when a player answers a trade request from another player.
 
|-
 
|-
Line 303: Line 303:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Unequip item
+
| [[317:Unequip item|Unequip item]]
 
| Sent when a player unequips an item.
 
| Sent when a player unequips an item.
 
|-
 
|-
Line 309: Line 309:
 
| VARIABLE_BYTE
 
| VARIABLE_BYTE
 
| N/A
 
| N/A
| Regular walk
+
| [[317:Regular walk|Regular walk]]
 
| Sent when the player walks regularly.
 
| Sent when the player walks regularly.
 
|-
 
|-
Line 315: Line 315:
 
| FIXED
 
| FIXED
 
| 2
 
| 2
| Button click
+
| [[317:Button click|Button click]]
 
| Sent when a player clicks an in-game button.
 
| Sent when a player clicks an in-game button.
 
|-
 
|-
Line 321: Line 321:
 
| FIXED
 
| FIXED
 
| 0
 
| 0
| Idle logout
+
| [[317:Idle logout|Idle logout]]
 
| Sent when the player has become idle and should be logged out.
 
| Sent when the player has become idle and should be logged out.
 
|-
 
|-
Line 327: Line 327:
 
| FIXED
 
| FIXED
 
| 10
 
| 10
| Bank x items part-2
+
| [[317:Bank X items part-2|Bank X items part-2]]
 
| Sent when a player enters an X amount of items they want to bank.
 
| Sent when a player enters an X amount of items they want to bank.
 
|-
 
|-
Line 333: Line 333:
 
| FIXED
 
| FIXED
 
| 7
 
| 7
| Move item
+
| [[317:Move item|Move item]]
 
| Moves an item from one interface to another.
 
| Moves an item from one interface to another.
 
|-
 
|-
Line 339: Line 339:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Pickup ground item
+
| [[317:Pickup ground item|Pickup ground item]]
 
| Sent when the player picks up an item from the ground.
 
| Sent when the player picks up an item from the ground.
 
|-
 
|-
Line 345: Line 345:
 
| VARIABLE_BYTE
 
| VARIABLE_BYTE
 
| N/A
 
| N/A
| Map walk
+
| [[317:Map walk|Map walk]]
 
| Sent when the player walks using the map. Has 14 additional (assumed to be anticheat) bytes added to the end of it that are ignored.
 
| Sent when the player walks using the map. Has 14 additional (assumed to be anticheat) bytes added to the end of it that are ignored.
 
|-
 
|-
Line 351: Line 351:
 
| FIXED
 
| FIXED
 
| 6
 
| 6
| Object action 2
+
| [[317:Object action 2|Object action 2]]
 
| Sent when the player clicks the second action available for an object.
 
| Sent when the player clicks the second action available for an object.
 
|-
 
|-
 
|}
 
|}

Revision as of 19:52, 15 August 2009

Login Protocol

(needs to be documented)

Response Codes

Towards the end of the login procedure, we send different values to the client to allow or deny a login. The various values show different messages on the login box on the client or do something internally.

Value Response
-1 Waits for 2000ms and tries again while counting failures.
0 Exchanges session keys, player name, password, etc.
1 Waits for 2000ms and tries again.
2 Client made a successful login.
3 "Invalid username or password."
4 "Your account has been disabled. Please check your message-center for details."
5 "Your account is already logged in. Try again in 60 secs..."
6 "RuneScape has been updated! Please reload this page."
7 "This world is full. Please use a different world."
8 "Unable to connect. Login server offline."
9 "Login limit exceeded. Too many connections from your address."
10 "Unable to connect. Bad session id."
11 "Login server rejected session. Please try again."
12 "You need a members account to login to this world. Please subscribe, or use a different world."
13 "Could not complete login. Please try using a different world."
14 "The server is being updated. Please wait 1 minute and try again."
15 N/A
16 "Login attempts exceeded. Please wait 1 minute and try again."
17 "You are standing in a members-only area. To play on this world move to a free area first."
20 "Invalid loginserver requested. Please try using a different world."
21 "You have only just left another world. Your profile will be transferred in: (number) seconds."
None of the above "Unexpected server response. Please try using a different world."

Game Protocol

(description)

Server -> Client Packets

Opcode Type Length (bytes) Name Description
1 FIXED 0 Animation reset Resets all animations in the immediate area.
71 FIXED 3 Send sidebar interface Assigns an interface to one of the tabs in the game sidebar.
73 FIXED 4 Load map region Loads a new map region.
97 FIXED 2 Show interface Displays a normal interface.
107 FIXED 0 Reset camera Resets the camera position.
109 FIXED 0 Logout Disconnects the client from the server.
110 FIXED 1 Run energy Sends the players run energy level.
114 FIXED 2 System update Sends how many seconds until a 'System Update.'
126 VARIABLE_SHORT N/A Send text Attaches text to an interface.
176 FIXED 10 Open welcome screen Displays the welcome screen.
219 FIXED 0 Clear screen Clears the screen of all open interfaces.
240 FIXED 2 Weight Sends the players weight amount.
241 VARIABLE_SHORT N/A Construct map region Constructs a dynamic map region using a palette of 8*8 tiles.
249 FIXED 3 Initialize player Sends the player's membership status and their current index on the server's player list.
253 VARIABLE_BYTE N/A Send message Sends a server message (e.g. 'Welcome to RuneScape') or trade/duel request.

Client -> Server Packets

Opcode Type Length (bytes) Name Description
0 FIXED 0 Idle Sent when there are no actions being performed by the player for this cycle.
3 FIXED 1 Focus change Sent when the game client window goes out of focus.
4 VARIABLE BYTE N/A Chat Sent when the player enters a chat message.
41 FIXED 6 Equip item Sent when a player equips an item.
43 FIXED 6 Bank 10 items Sent when a player banks 10 of a certain item.
70 FIXED 6 Object action 3 Sent when the player clicks the third action available for an object.
73 FIXED 2 Trade request Sent when a player requests a trade with another player.
86 FIXED 4 Camera movement Sent when the player moves the camera.
87 FIXED 6 Drop item Sent when a player wants to drop an item onto the ground.
98 VARIABLE_BYTE N/A Walk on command Sent when the player should walk somewhere according to a certain action performed, such as clicking an object.
103 VARIABLE_BYTE N/A Player command Sent when the player enters a command in the chat box (i.e. "::command")
117 FIXED 6 Bank 5 items Sent when a player banks 5 of a certain item.
121 FIXED 0 Loading finished Sent when the client finishes loading a map region.
122 FIXED 6 Item action 1 Sent when the player clicks the first option of an item, such as "Bury" for bones.
129 FIXED 6 Bank all items Sent when a player banks all of a certain item that they have in their inventory.
132 FIXED 6 Object action 1 Sent when the player clicks the first option of an object, such as "Cut" for trees.
135 FIXED 6 Bank X items part-1 Sent when a player requests to bank an X amount of items.
139 FIXED 2 Trade answer Sent when a player answers a trade request from another player.
145 FIXED 6 Unequip item Sent when a player unequips an item.
164 VARIABLE_BYTE N/A Regular walk Sent when the player walks regularly.
185 FIXED 2 Button click Sent when a player clicks an in-game button.
202 FIXED 0 Idle logout Sent when the player has become idle and should be logged out.
208 FIXED 10 Bank X items part-2 Sent when a player enters an X amount of items they want to bank.
214 FIXED 7 Move item Moves an item from one interface to another.
236 FIXED 6 Pickup ground item Sent when the player picks up an item from the ground.
248 VARIABLE_BYTE N/A Map walk Sent when the player walks using the map. Has 14 additional (assumed to be anticheat) bytes added to the end of it that are ignored.
252 FIXED 6 Object action 2 Sent when the player clicks the second action available for an object.