├── .gitignore ├── src ├── 317 │ ├── 317-Begin-player-updating.md │ ├── 317-Mouse-click.md │ ├── 317-NPC-Dialogue.md │ ├── 317-Idle.md │ ├── 317-Object-removal.md │ ├── 317-Reset-camera.md │ ├── 317-Clear-screen.md │ ├── 317-Region-change.md │ ├── 317-Logout.md │ ├── 317-Animation-reset.md │ ├── 317-Reset-button-state.md │ ├── 317-Loading-finished.md │ ├── 317-Enter-name.md │ ├── 317-Close-window.md │ ├── 317-Reset-destination.md │ ├── 317-Input-amount.md │ ├── 317-Object-spawn.md │ ├── 317-Display-hint-icon.md │ ├── 317-Send-add-friend.md │ ├── 317-Show-interface.md │ ├── 317-Show-tab.md │ ├── 317-Run-energy.md │ ├── 317-Idle-logout.md │ ├── 317-Weight.md │ ├── 317-Friends-list-status.md │ ├── 317-Add-friend.md │ ├── 317-Add-ignore.md │ ├── 317-Attack-(NPC).md │ ├── 317-Button-click.md │ ├── 317-Play-song.md │ ├── 317-Chat-interface.md │ ├── 317-Remove-friend.md │ ├── 317-Interface-over-tab.md │ ├── 317-Remove-ignore.md │ ├── 317-Ground-Item-Action.md │ ├── 317-Walkable-interface.md │ ├── 317-Chat-interface-click.md │ ├── 317-Interface-animation.md │ ├── 317-NPC-action-1.md │ ├── 317-Follow.md │ ├── 317-Music.md │ ├── 317-Hidden-Interface.md │ ├── 317-Trade-request.md │ ├── 317-Bank-X-items-part-2.md │ ├── 317-Trade-answer.md │ ├── 317-Audio.md │ ├── 317-NPC-action-2.md │ ├── 317-Chat-settings.md │ ├── 317-NPC-action-3.md │ ├── 317-Send-Skill.md │ ├── 317-Clear-inventory.md │ ├── 317-Player-command.md │ ├── 317-Player-head-to-interface.md │ ├── 317-Focus-change.md │ ├── 317-Mage-NPC.md │ ├── 317-Camera-movement.md │ ├── 317-Item-on-item.md │ ├── 317-Open-chatbox-interface.md │ ├── 317-Send-private-message.md │ ├── 317-Interface-item.md │ ├── 317-Skill-level.md │ ├── 317-Scroll-position.md │ ├── 317-Magic-on-player.md │ ├── 317-Light-item.md │ ├── 317-Report-player.md │ ├── 317-Interface-offset.md │ ├── 317-Privacy-options.md │ ├── 317-Minimap-State.md │ ├── 317-Player-Option.md │ ├── 317-Drop-item.md │ ├── 317-Equip-item.md │ ├── 317-Show-multi-combat.md │ ├── 317-Song-Queue.md │ ├── 317-Send-message.md │ ├── 317-Initialize-player.md │ ├── 317-NPC-head-on-interface.md │ ├── 317-Unequip-item.md │ ├── 317-Set-interface-text.md │ ├── 317-Pickup-ground-item.md │ ├── 317-Item-on-player.md │ ├── 317-Bank-X-items-part-1.md │ ├── 317-Object-action-3.md │ ├── 317-Magic-on-items.md │ ├── 317-System-update.md │ ├── 317-Bank-10-items.md │ ├── 317-Object-action-1.md │ ├── 317-Interface-model-rotation.md │ ├── 317-Bank-all-items.md │ ├── 317-Flash-sidebar.md │ ├── 317-Item-action-1.md │ ├── 317-Inventory-overlay.md │ ├── 317-Object-action-2.md │ ├── 317-Move-item.md │ ├── 317-Alternate-item-option-2.md │ ├── 317-Bank-5-items.md │ ├── 317-Interface-color.md │ ├── 317-Open-welcome-screen.md │ ├── 317-Send-add-ignore.md │ ├── 317-Create-Projectile.md │ ├── 317-Force-client-setting.md │ ├── 317-Update-item-container.md │ ├── 317-Load-map-region.md │ ├── 317-Item-on-object.md │ ├── 317-Send-sidebar-interface.md │ ├── 317-Item-on-floor.md │ ├── 317-Design-screen.md │ ├── 317-Construct-map-region.md │ └── 317-Camera-shake.md ├── 377 │ ├── 377-Animation-Reset.md │ ├── 377-Reset-Button-State.md │ ├── 377-Input-Amount.md │ ├── 377-Logout.md │ ├── 377-Run-Energy.md │ ├── 377-Walkable-Interface.md │ ├── 377-Send-Message.md │ ├── 377-Send-Add-Friend.md │ ├── 377-Send-Sound.md │ ├── 377-Interface-Animation.md │ ├── 377-Skill-Level.md │ ├── 377-Play-Ambient-Wave.md │ ├── 377-Send-Sidebar-Interface.md │ ├── 377-Create-Static-Graphic.md │ ├── 377-Interface-Item.md │ ├── 377-Move-Camera.md │ ├── 377-Initialize-Player.md │ ├── 377-Reset-Ground-Items-and-Objects.md │ ├── 377-Send-Ground-Item.md │ ├── 377-Inventory-Overlay.md │ ├── 377-Camera-Shake.md │ ├── 377-Construct-Map-Region.md │ ├── 377-Open-Welcome-Screen.md │ └── 377-Protocol.md ├── img │ ├── map-region-system-diagram.png │ └── map-region-system-loading.png ├── Word.md ├── QWord.md ├── DWord.md ├── General-disclaimer.md ├── DMCA-policy.md ├── Client-functions.md ├── Data.md ├── 194-Clear-screen.md ├── 194-Logout.md ├── 718-Open-URL.md ├── 289-Send-Player-Head.md ├── 194-Show-interface.md ├── 718-Player-under-NPC-priority.md ├── RS-String.md ├── 289-Send-sidebar-interface.md ├── 718-Music-effect.md ├── 718-Close-window.md ├── 474-Remove-ignore.md ├── Mouse-coordinate-tracking.md ├── Home.md ├── 718-Interface.md ├── 474-Fourth-Interface-Option.md ├── 289-Player-Dialogue-Head.md ├── Rules.md ├── 718-Friends-packet.md ├── Censorship.md ├── 357-Protocol.md ├── IRC.md ├── Ondemand-Protocol.md ├── ISAAC-cipher.md ├── About.md ├── 464-Protocol.md ├── 468-Protocol.md ├── 289-Construct-Map-Region.md ├── 634-Protocol.md ├── 194-Protocol.md ├── 668-Protocol.md ├── 742-Protocol.md ├── JAGGRAB-Protocol.md ├── RuneScape-Protocol.md ├── Privacy-policy.md ├── 718-Protocol.md ├── 474-Protocol.md ├── Data-Types.md ├── Class-Check.md ├── OB3.md ├── 508-Protocol.md ├── Archive-Format.md ├── Map-Region-System.md ├── 202-Protocol.md ├── 204-Protocol.md └── SUMMARY.md ├── book.toml └── readme.md /.gitignore: -------------------------------------------------------------------------------- 1 | book 2 | -------------------------------------------------------------------------------- /src/317/317-Begin-player-updating.md: -------------------------------------------------------------------------------- 1 | # Player Updating 2 | This packet begins the player updating. 3 | -------------------------------------------------------------------------------- /book.toml: -------------------------------------------------------------------------------- 1 | [book] 2 | authors = ["moparisthebest"] 3 | multilingual = false 4 | src = "src" 5 | title = "RSWiki" 6 | -------------------------------------------------------------------------------- /src/317/317-Mouse-click.md: -------------------------------------------------------------------------------- 1 | # Mouse click 2 | This packet is sent when a player clicks somewhere on the game screen. 3 | -------------------------------------------------------------------------------- /src/317/317-NPC-Dialogue.md: -------------------------------------------------------------------------------- 1 | # NPC Dialogue 2 | This packet is what handles when the player hits the "Click here to continue". 3 | -------------------------------------------------------------------------------- /src/img/map-region-system-diagram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/moparisthebest/rswiki-book/HEAD/src/img/map-region-system-diagram.png -------------------------------------------------------------------------------- /src/img/map-region-system-loading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/moparisthebest/rswiki-book/HEAD/src/img/map-region-system-loading.png -------------------------------------------------------------------------------- /src/Word.md: -------------------------------------------------------------------------------- 1 | # Word 2 | 3 | A "word" is a data-type that consists of 2 bytes. 4 | It is also commonly known as the "short" data-type in programming. 5 | -------------------------------------------------------------------------------- /src/QWord.md: -------------------------------------------------------------------------------- 1 | # QWord 2 | 3 | A "QWord" (quad-word) is a data-type that consists of 8 bytes. 4 | It is also commonly known as the "long" data-type in programming. 5 | -------------------------------------------------------------------------------- /src/DWord.md: -------------------------------------------------------------------------------- 1 | # DWord 2 | 3 | A "DWord" (double-word) is a data-type that consists of 4 bytes. 4 | It is also commonly known as the "int" data-type in programming. 5 | -------------------------------------------------------------------------------- /src/General-disclaimer.md: -------------------------------------------------------------------------------- 1 | All information provided on this wiki is provided AS IS and contains NO WARRANTY. All information provided is purely for educational purposes only. -------------------------------------------------------------------------------- /readme.md: -------------------------------------------------------------------------------- 1 | RSWiki converted to [mdBook](https://github.com/rust-lang-nursery/mdBook) format, follow [usage](https://github.com/rust-lang-nursery/mdBook#usage) instructions there. 2 | -------------------------------------------------------------------------------- /src/DMCA-policy.md: -------------------------------------------------------------------------------- 1 | If you find something on this wiki page that infringes on your 2 | intellectual rights, please contact admin [at] moparisthebest.com to 3 | ask for the content's removal. 4 | -------------------------------------------------------------------------------- /src/Client-functions.md: -------------------------------------------------------------------------------- 1 | # Client functions 2 | 3 | This section will describe the following: 4 | - [Map region system](./Map-Region-System.html) 5 | - [Censorship](./Censorship.html) 6 | - [Mouse coordinate tracking](./Mouse-coordinate-tracking.html) 7 | - [Class-Check](./Class-Check.html) 8 | -------------------------------------------------------------------------------- /src/Data.md: -------------------------------------------------------------------------------- 1 | # Data 2 | 3 | This section covers the raw data-related facilities and systems within the Client. 4 | 5 | This includes an overview of the [data-types](./Data-Types.md) used, as well as 6 | protocols like [JAGGRAB Protocol](./JAGGRAB-Protocol.md) and 7 | [Ondemand Protocol](./Ondemand-Protocol.md). 8 | -------------------------------------------------------------------------------- /src/317/317-Idle.md: -------------------------------------------------------------------------------- 1 | # Idle 2 | Sent when the player is idle for the current cycle, and acts as a "ping" packet. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Idle | 8 | | Description | Idle packet.. | 9 | | Opcode | 0 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/194-Clear-screen.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 194\]\] {{packet\|name=Clear 2 | screen\|description=Clears the screen of all open 3 | interfaces.\|opcode=240\|type=Fixed\|length=0\|revision=194}} == Clear 4 | Screen == 5 | 6 | === Description === 7 | 8 | Removes all open interfaces from the players screen. 9 | -------------------------------------------------------------------------------- /src/317/317-Object-removal.md: -------------------------------------------------------------------------------- 1 | # Object removal 2 | This packet requests the client to remove an object. 3 | 4 | ## Packet Structure 5 | | Data Type | Description | 6 | |--|--| 7 | | Unsigned [Byte](/Data-Types.html#common-data-types) | `object_type << 2 + object_rotation & 3` | 8 | | [Byte](/Data-Types.html#common-data-types) | `0` | 9 | -------------------------------------------------------------------------------- /src/317/317-Reset-camera.md: -------------------------------------------------------------------------------- 1 | # Reset Camera 2 | Resets the game's camera position to the client default. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Reset camera | 8 | | Description | Resets the camera position. | 9 | | Opcode | 107 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/377/377-Animation-Reset.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Animation Reset\|description=Resets all animations in the 3 | immediate area.\|opcode=13\|type=Fixed\|length=0\|revision=377}} == 4 | Animation Reset == 5 | 6 | === Description === 7 | 8 | Resets all animations in the immediate area. 9 | -------------------------------------------------------------------------------- /src/377/377-Reset-Button-State.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Reset 2 | Button State\|description=Resets the button state for all 3 | buttons.\|opcode=113\|type=Fixed\|length=0\|revision=377}} == Reset 4 | Button State == 5 | 6 | === Description === 7 | 8 | Resets the button state for all buttons. 9 | -------------------------------------------------------------------------------- /src/317/317-Clear-screen.md: -------------------------------------------------------------------------------- 1 | # Clear Screen 2 | Removes all open interfaces from the players screen. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Clear screen | 8 | | Description | Clears the screen of all open interfaces. | 9 | | Opcode | 219 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/377/377-Input-Amount.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Input 2 | Amount\|description=Forces the client to open the input amount 3 | interface.\|opcode=58\|type=Fixed\|length=0\|revision=377}} == Input 4 | Amount == 5 | 6 | === Description === 7 | 8 | Forces the client to open the input amount interface. 9 | -------------------------------------------------------------------------------- /src/377/377-Logout.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Logout\|description=Forces the client to 3 | logout.\|opcode=5\|type=Fixed\|length=0\|revision=377}} == Logout == 4 | 5 | === Description === 6 | 7 | Forces the client to logout cleanly and return to the login screen, 8 | without attempting a reconnection. 9 | -------------------------------------------------------------------------------- /src/317/317-Region-change.md: -------------------------------------------------------------------------------- 1 | # Region Change 2 | This packet is sent when a player enters a new map region. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Region change | 8 | | Description | Sent when a player enters a new map region. | 9 | | Opcode | 210 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/194-Logout.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 194\]\] 2 | {{packet\|name=Logout\|description=Forces the client to 3 | logout.\|opcode=192\|type=Fixed\|length=0\|revision=194}} == Send 4 | Message == 5 | 6 | === Description === 7 | 8 | Forces the client to logout cleanly and return to the login screen, 9 | without attempting a reconnection. 10 | -------------------------------------------------------------------------------- /src/317/317-Logout.md: -------------------------------------------------------------------------------- 1 | # Logout 2 | Forces the client to logout cleanly and return to the login screen, without attempting a reconnection. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Logout | 8 | | Description | Forces the client to logout. | 9 | | Opcode | 109 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Animation-reset.md: -------------------------------------------------------------------------------- 1 | # Animation Reset 2 | Resets all animations for players and npcs in the surrounding area. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Animation reset | 8 | | Description | Resets all animations in the immediate area. | 9 | | Opcode | 1 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Reset-button-state.md: -------------------------------------------------------------------------------- 1 | # Reset setting states 2 | This packet resets the states for all user settings (inc. buttons). 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Reset setting states | 8 | | Description | Resets the states for all settings. | 9 | | Opcode | 68 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Loading-finished.md: -------------------------------------------------------------------------------- 1 | # Loading Finished 2 | This packet is sent when a player is finished loading a new map region. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Loading finished | 8 | | Description | Sent when the player is finished loading a map region | 9 | | Opcode | 121 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Enter-name.md: -------------------------------------------------------------------------------- 1 | # Enter name 2 | Sending the packet to the client will make the client open up the "Enter name" interface for things such as friend-adding. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Enter name | 8 | | Description | Opens up the name entry interface. | 9 | | Opcode | 187 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Close-window.md: -------------------------------------------------------------------------------- 1 | # Close Window 2 | This packet is sent when a player presses the close, exit or cancel button on an interface. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Close window | 8 | | Description | Sent when a player presses the close, exit or cancel button on an interface. | 9 | | Opcode | 130 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Reset-destination.md: -------------------------------------------------------------------------------- 1 | # Reset destination 2 | Sending the packet to the client will make the client reset the player's destination and effectively stop them from walking. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Reset destination | 8 | | Description | Resets the player's destination. | 9 | | Opcode | 78 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Input-amount.md: -------------------------------------------------------------------------------- 1 | # Input amount 2 | Sending the packet to the client will make the client open up the "Input amount" interface over the chatbox for things such as Buy X and Bank X. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Input amount | 8 | | Description | Opens up the amount input interface. | 9 | | Opcode | 27 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/317/317-Object-spawn.md: -------------------------------------------------------------------------------- 1 | # Object spawn 2 | This packet requests the client to spawn an object. 3 | 4 | ## Packet Structure 5 | | Data Type | Description | 6 | |--|--| 7 | | Subtrahend [Byte](/Data-Types.html#common-data-types) | 0 | 8 | | [Little Endian](/Data-Types.html#little-endian) [Byte](/Data-Types.html#common-data-types) | Object ID | 9 | | Subtrahend [Byte](/Data-Types.html#common-data-types) | `object_type << 2 + object_rotation & 3` | 10 | -------------------------------------------------------------------------------- /src/718-Open-URL.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 718\]\] {{packet\|name=Open 2 | URL\|description=Opens a 3 | hyperlink.\|opcode=17\|type=VARIABLE\_SHORT\|length=-2\|revision=718}} 4 | == Close window == 5 | 6 | === Description === 7 | 8 | Opens a hyperlink sent (doesn't write to the chatbox, just opens). 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| Byte \|\| ? \|- \| String 13 | \|\| The URL. \|} 14 | -------------------------------------------------------------------------------- /src/289-Send-Player-Head.md: -------------------------------------------------------------------------------- 1 | {{packet\|name=Send player head\|description=Sends the player head on an 2 | interface\|opcode=185\|type=Fixed\|length=5\|revision=317}} 3 | 4 | == Friends List Status == 5 | 6 | === Description === 7 | 8 | This packet sends the first list load status. 9 | 10 | === Packet Structure === {\|border=2 ! Data Type ! Description \|- \| 11 | \[\[Data Types\#Standard data types\|Little Endian Short-A\]\] \| The 12 | interface Id. \|- \|} 13 | -------------------------------------------------------------------------------- /src/317/317-Display-hint-icon.md: -------------------------------------------------------------------------------- 1 | # Display Hint Icon 2 | Displays a hint icon. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Display hint icon | 8 | | Description | Display a hint icon to the player. | 9 | | Opcode | 254 | 10 | | Type | Variable Byte | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | The Icon type | 18 | -------------------------------------------------------------------------------- /src/317/317-Send-add-friend.md: -------------------------------------------------------------------------------- 1 | # Send Add Friend 2 | Sends friend data to the client 3 | 4 | Attempts to update player node, if player isn't in the friends list and there is space, the player is added to the friend list. 5 | 6 | ## Packet Structure 7 | | Data type | Description | 8 | |--|--| 9 | | [Long](/Data-Types.html#common-data-types) | Player name | 10 | | [Byte](/Data-Types.html#common-data-types) | The world (10 = "online" in world 1, 0 = logged out) | 11 | -------------------------------------------------------------------------------- /src/317/317-Show-interface.md: -------------------------------------------------------------------------------- 1 | # Show Interface 2 | Displays a normal non-walkable interface. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Show interface | 8 | | Description | Displays a normal interface. | 9 | | Opcode | 97 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The interface id. | 18 | -------------------------------------------------------------------------------- /src/317/317-Show-tab.md: -------------------------------------------------------------------------------- 1 | # Show Tab 2 | Shows the given tab id. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Show Tab | 8 | | Description | Shows the given tab. | 9 | | Opcode | 106 | 10 | | Type | Fixed | 11 | | Length | 1 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | U [Byte](/Data-Types.html#common-data-types) [Special C](/Data-Types.html#bespoke-data-types) | Tab ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Run-energy.md: -------------------------------------------------------------------------------- 1 | # Run Energy 2 | Sends how much run energy the player currently has. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Run energy | 8 | | Description | Sends the players run energy level. | 9 | | Opcode | 110 | 10 | | Type | Fixed | 11 | | Length | 1 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | The energy level. | 18 | -------------------------------------------------------------------------------- /src/194-Show-interface.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 194\]\] {{packet\|name=Show 2 | interface\|description=Displays a normal 3 | interface.\|opcode=137\|type=Fixed\|length=2\|revision=194}} == Show 4 | interface == 5 | 6 | === Description === 7 | 8 | Displays a normal interface with the given id. 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 13 | data types\|Short\]\] \| The interface id. \|- \|} 14 | -------------------------------------------------------------------------------- /src/317/317-Idle-logout.md: -------------------------------------------------------------------------------- 1 | # Idle logout 2 | This is sent when the player becomes idle and should be logged out. This is sent after the player is idle for 60 seconds, after that it is sent every 10 seconds as long as the player is idle. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Idle logout | 8 | | Description | Sent when the player has become idle and should be logged out. | 9 | | Opcode | 202 | 10 | | Type | Fixed | 11 | | Length | 0 | 12 | | Revision | 317 | 13 | -------------------------------------------------------------------------------- /src/377/377-Run-Energy.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Run 2 | Energy\|description=Sends the players run energy 3 | level.\|opcode=125\|type=Fixed\|length=1\|revision=377}} == Run Energy 4 | == 5 | 6 | === Description === Sends the players run energy level. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| Unsigned \[\[Data 11 | Types\#Standard data types\|Byte\]\] \| The amount of energy remaining. 12 | \|- \|} 13 | -------------------------------------------------------------------------------- /src/718-Player-under-NPC-priority.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 718\]\] 2 | {{packet\|name=Player under NPC priority\|description=Prioritizes the 3 | player under the NPC.\|opcode=6\|type=Fixed\|length=1\|revision=718}} == 4 | Player under NPC priority == 5 | 6 | === Description === 7 | 8 | Prioritizes the player under the NPC. 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| Byte C \|\| If is to 13 | prioritize (1) or not (0). \|} 14 | -------------------------------------------------------------------------------- /src/317/317-Weight.md: -------------------------------------------------------------------------------- 1 | # Weight 2 | Sends how much weight of equipment the player is wearing (e.g. Rune plate-body is 9.04kg). 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Weight | 8 | | Description | Sends the players weight amount. | 9 | | Opcode | 240 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The amount of weight. | 18 | -------------------------------------------------------------------------------- /src/RS-String.md: -------------------------------------------------------------------------------- 1 | # RS String 2 | 3 | RS String is the internal name for a custom string data-type used in the 4 | RuneScape protocol. 5 | The string data-type stores a collection of characters in order to 6 | represent a textual message. 7 | 8 | ## Old Engine 9 | 10 | In the old engine client, the RS String datatype is terminated by the new line 11 | character (i.e. `\n`). 12 | 13 | # New Engine 14 | 15 | In the new-engine client, the RS String datatype is terminated by a null byte (i.e. `0`). 16 | -------------------------------------------------------------------------------- /src/289-Send-sidebar-interface.md: -------------------------------------------------------------------------------- 1 | {{packet\|name=Send Sidebar Interface\|description=Sends the sidebar 2 | interfaces\|opcode=63\|type=Fixed\|length=3\|revision=317}} == Send 3 | Sidebar Interface == 4 | 5 | === Description === 6 | 7 | This packet sends the sidebar interfaces 8 | 9 | === Packet Structure === {\|border=2 ! Data Type ! Description \|- \| 10 | \[\[Data Types\#Standard data types\|Short\]\] \| The interface Id. \|- 11 | \| \[\[Data Types\#Standard data types\|Byte\]\] \| The icon. \|- \|} 12 | -------------------------------------------------------------------------------- /src/317/317-Friends-list-status.md: -------------------------------------------------------------------------------- 1 | # Friends List Status 2 | This packet sends the first list load status. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Friends list status | 8 | | Description | Sends the friends list load status | 9 | | Opcode | 221 | 10 | | Type | Fixed | 11 | | Length | 1 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | The status of the friends list. | 18 | -------------------------------------------------------------------------------- /src/377/377-Walkable-Interface.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Walkable interface\|description=Displays an interface in 3 | walkable mode.\|opcode=50\|type=Fixed\|length=2\|revision=377}} == 4 | Walkable Interface == 5 | 6 | === Description === 7 | 8 | This packet displays an interface in walkable mode. 9 | 10 | === Packet Structure === {\|border=2 ! Data Type ! Description \|- \| 11 | \[\[Data Types\#Standard data types\|Short\]\] \| Interface ID. \|- \|} 12 | -------------------------------------------------------------------------------- /src/718-Music-effect.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 718\]\] {{packet\|name=Music 2 | effect\|description=Plays a music 3 | effect.\|opcode=9\|type=Fixed\|length=6\|revision=718}} == Music effect 4 | == 5 | 6 | === Description === 7 | 8 | Plays a sound effect (like the birds chirping). 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| 128 Byte \|\| The volume 13 | (0 - 255). \|- \| 24 Bit Integer V2 \|\| ? \|- \| Short \|\| Music 14 | effect ID. \|} 15 | -------------------------------------------------------------------------------- /src/317/317-Add-friend.md: -------------------------------------------------------------------------------- 1 | # Add Friend 2 | This packet is sent when a player adds a friend to their friends list. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Add friend | 8 | | Description | Sent when a player adds a friend to their friends list. | 9 | | Opcode | 188 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Long](/Data-Types.html#common-data-types) | The other players ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Add-ignore.md: -------------------------------------------------------------------------------- 1 | # Add Ignore 2 | This packet is sent when a player adds another player to their ignore list. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Add ignore | 8 | | Description | Sent when a player adds another player to their ignore list. | 9 | | Opcode | 133 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Long](/Data-Types.html#common-data-types) | The other players ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Attack-(NPC).md: -------------------------------------------------------------------------------- 1 | # Description 2 | This packet is sent when a player attacks an NPC. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Attack (NPC) | 8 | | Description | Sent when a player attacks an NPC | 9 | | Opcode | 72 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The NPC ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Button-click.md: -------------------------------------------------------------------------------- 1 | # Button click 2 | This is sent when a player clicks a button in-game, with the id of the button being clicked. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Button click | 8 | | Description | Sent when a player clicks an in-game button. | 9 | | Opcode | 185 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The button id. | 18 | -------------------------------------------------------------------------------- /src/317/317-Play-song.md: -------------------------------------------------------------------------------- 1 | # Play song 2 | Sending this packet to the client will cause the client to start playing a song. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Play song | 8 | | Description | Starts playing a song. | 9 | | Opcode | 74 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The song ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Chat-interface.md: -------------------------------------------------------------------------------- 1 | # Chat Interface 2 | This packet attaches an interface to the chat box. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Chat interface | 8 | | Description | Shows an interface in the chat box. | 9 | | Opcode | 164 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The interface ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Remove-friend.md: -------------------------------------------------------------------------------- 1 | # Remove Friend 2 | This packet is sent when a player removes a friend from their friends list. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Remove friend | 8 | | Description | Sent when a player removes a friend from their friend list. | 9 | | Opcode | 215 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Long](/Data-Types.html#common-data-types) | The other players ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Interface-over-tab.md: -------------------------------------------------------------------------------- 1 | # Open Welcome Screen 2 | This packet draws an interface over the tab area. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Interface over tab | 8 | | Description | Draws an interface over the tab area. | 9 | | Opcode | 106 | 10 | | Type | Fixed | 11 | | Length | 1 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) [Special C](/Data-Types.html#bespoke-data-types) | Interface ID | 18 | -------------------------------------------------------------------------------- /src/317/317-Remove-ignore.md: -------------------------------------------------------------------------------- 1 | # Remove Ignore 2 | This packet is sent when a player removes another player from their ignore list. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Remove ignore | 8 | | Description | Sent when a player removes another player from their ignore list. | 9 | | Opcode | 74 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Long](/Data-Types.html#common-data-types) | The other players ID. | 18 | -------------------------------------------------------------------------------- /src/377/377-Send-Message.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Send 2 | Message\|description=Sends a server message (e.g. 'Welcome to 3 | RuneScape') or trade/duel request.\|opcode=63\|type=Variable 4 | Byte\|length=N/A\|revision=377}} == Send Message == 5 | 6 | === Description === Sends a server message (e.g. 'Welcome to RuneScape') 7 | or trade/duel request. 8 | 9 | === Packet Structure === 10 | 11 | {\| border=2 ! Data type ! Description \|- \| \[\[RS String\|RS 12 | String\]\] \| Message. \|- \|} 13 | -------------------------------------------------------------------------------- /src/718-Close-window.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 718\]\] {{packet\|name=Close 2 | window\|description=Closes a 3 | window/interface.\|opcode=5\|type=Fixed\|length=4\|revision=718}} == 4 | Close window == 5 | 6 | === Description === 7 | 8 | Closes an interface that is displayed (NOT CHATBOX INTERFACES!). 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Little 13 | Endian\|Little Endian\]\] \[\[Data Types\#Standard data types\|Int\]\] 14 | \|\| Window ID. \|} 15 | -------------------------------------------------------------------------------- /src/317/317-Ground-Item-Action.md: -------------------------------------------------------------------------------- 1 | # Ground Item Action 2 | This packet is sent when a player clicks the first option on a ground item. 3 | 4 | ## Packet Structure 5 | | Data Type | Description | 6 | |--|--| 7 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The items X coordinate. | 8 | | Additional [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The items Y coordinate. | 9 | | Additional [Short](/Data-Types.html#common-data-types) | The item ID. | 10 | -------------------------------------------------------------------------------- /src/317/317-Walkable-interface.md: -------------------------------------------------------------------------------- 1 | # Walkable Interface 2 | This packet displays an interface in walkable mode. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Walkable interface | 8 | | Description | Displays an interface in walkable mode. | 9 | | Opcode | 208 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | Interface ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Chat-interface-click.md: -------------------------------------------------------------------------------- 1 | # Chat interface click 2 | Received by the server when a button is pressed in a [Chat interface](Chat-interface.html). 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Chat interface click | 8 | | Description | Received when a button is pressed, in a chat interface. | 9 | | Opcode | 40 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | Frame ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Interface-animation.md: -------------------------------------------------------------------------------- 1 | # Interface animation 2 | Sets an interface's model animation. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Interface animation | 8 | | Description | Sets an interface's model animation | 9 | | Opcode | 200 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The interface ID | 18 | | [Short](/Data-Types.html#common-data-types) | The animation ID | 19 | -------------------------------------------------------------------------------- /src/474-Remove-ignore.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 474\]\] 2 | {{packet\|name=Remove ignore\|description=Sent when a player removes a 3 | player from their ignore 4 | list.\|opcode=1\|type=Fixed\|length=8\|revision=474}} == Remove ignore 5 | == 6 | 7 | === Description === 8 | 9 | Signals the player wants to remove an ignore. 10 | 11 | === Packet Structure === {\|border=2 ! Data Type ! Description \|- \| 12 | \[\[Data Types\#Standard data types\|Long\]\] \| The player that is 13 | going to be removed from the ignore's name. \|- \|} 14 | -------------------------------------------------------------------------------- /src/317/317-NPC-action-1.md: -------------------------------------------------------------------------------- 1 | # NPC Action 1 2 | This packet is sent when a player clicks the first option of an NPC. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | NPC action 1 | 8 | | Description | Sent when a player clicks the first option of an NPC. | 9 | | Opcode | 155 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The NPC index. | 18 | -------------------------------------------------------------------------------- /src/317/317-Follow.md: -------------------------------------------------------------------------------- 1 | # Follow 2 | This packet is sent when a player clicks the follow option on another player. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Follow | 8 | | Description | Sent when a player clicks the follow option on another player | 9 | | Opcode | 39 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | Unsigned [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The other players ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Music.md: -------------------------------------------------------------------------------- 1 | # Audio 2 | Sets what audio to play at a certain moment. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Audio | 8 | | Description | Sets the audio to play. | 9 | | Opcode | 174 | 10 | | Type | Fixed | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The sound id. | 18 | | [Byte](/Data-Types.html#common-data-types) | The volume. | 19 | | [Short](/Data-Types.html#common-data-types) | The delay. | 20 | -------------------------------------------------------------------------------- /src/Mouse-coordinate-tracking.md: -------------------------------------------------------------------------------- 1 | # Mouse coordinate tracking 2 | 3 | There is a mechanicsm of mouse coordinate tracking within the client. 4 | This records the `(x, y)` coordinates of the mouse, and sends them 5 | back to the server each tick. 6 | 7 | When the client connects with the server, after it receives 8 | the player privilege, it receives a byte denoting whether or not 9 | the client should send these coordinates to the server periodically. 10 | 11 | ## Packet structure 12 | ``` 13 | byte opcode = 45; 14 | byte dummy = 0; 15 | byte[] mouse_data; 16 | ``` 17 | -------------------------------------------------------------------------------- /src/317/317-Hidden-Interface.md: -------------------------------------------------------------------------------- 1 | # Hidden Interface 2 | Sets an interface to be hidden until hovered over. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Hidden interface | 8 | | Description | Sets an interface to be hidden until hovered over. | 9 | | Opcode | 171 | 10 | | Type | Fixed | 11 | | Length | 3 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | Hidden until hovered | 18 | | [Short](/Data-Types.html#common-data-types) | Interface Id | 19 | -------------------------------------------------------------------------------- /src/317/317-Trade-request.md: -------------------------------------------------------------------------------- 1 | # Trade Request 2 | This packet is sent when a player requests a trade with another player. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Trade request | 8 | | Description | Sent when a player requests a trade with another player. | 9 | | Opcode | 73 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The other players ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Bank-X-items-part-2.md: -------------------------------------------------------------------------------- 1 | # Bank X Items Part-2 2 | This packet is sent when a player enters an X amount of items they want to bank. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | bank x items part-2 | 8 | | Description | Sent when a player enters an X amount of items they want to bank. | 9 | | Opcode | 208 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Int](/Data-Types.html#common-data-types) | The amount of the item you want to bank. | 18 | -------------------------------------------------------------------------------- /src/377/377-Send-Add-Friend.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Send 2 | Add Friend\|description=Sends a friend to be added to the friend 3 | list.\|opcode=78\|type=Fixed\|length=9\|revision=377}} == Send Add 4 | Friend == 5 | 6 | === Description === Sends a friend to be added to the friend list. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Long\]\] \| Player name (as long). \|- \| Unsigned \[\[Data 12 | Types\#Standard data types\|Byte\]\] \| World. \|- \|} 13 | -------------------------------------------------------------------------------- /src/317/317-Trade-answer.md: -------------------------------------------------------------------------------- 1 | # Trade Answer 2 | This packet is sent when a player answers a trade request from another player. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Trade answer | 8 | | Description | Sent when a player answers a trade request from another player. | 9 | | Opcode | 139 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The player requesting the trade's ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Audio.md: -------------------------------------------------------------------------------- 1 | # Audio 2 | Sets what audio/sound is to play at a certain moment. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Audio | 8 | | Description | Sets what audio/sound is to play at a certain moment. | 9 | | Opcode | 147 | 10 | | Type | Fixed | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The sound id. | 18 | | [Byte](/Data-Types.html#common-data-types) | The volume. | 19 | | [Short](/Data-Types.html#common-data-types) | The delay. | 20 | -------------------------------------------------------------------------------- /src/317/317-NPC-action-2.md: -------------------------------------------------------------------------------- 1 | # NPC Action 2 2 | This packet is sent when a player clicks the second action of an NPC. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | NPC action 2 | 8 | | Description | Sent when a player clicks the second action of an NPC. | 9 | | Opcode | 17 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The NPC index. | 18 | -------------------------------------------------------------------------------- /src/317/317-Chat-settings.md: -------------------------------------------------------------------------------- 1 | # Chat Settings 2 | This packet sends the chat privacy settings. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Chat settings | 8 | | Description | Sends the chat privacy settings | 9 | | Opcode | 206 | 10 | | Type | Fixed | 11 | | Length | 3 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | Public chat setting. | 18 | | [Byte](/Data-Types.html#common-data-types) | Private chat setting. | 19 | | [Byte](/Data-Types.html#common-data-types) | Trade setting. | 20 | -------------------------------------------------------------------------------- /src/317/317-NPC-action-3.md: -------------------------------------------------------------------------------- 1 | # NPC Action 3 2 | This packet is sent when a player clicks the third option of an NPC. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | NPC action 3 | 8 | | Description | Sent when a player clicks the third option of an NPC. | 9 | | Opcode | 21 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | Unsigned [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The NPC index. | 18 | -------------------------------------------------------------------------------- /src/317/317-Send-Skill.md: -------------------------------------------------------------------------------- 1 | # Send Skill 2 | This packet sends a specific skill. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Send Skill | 8 | | Description | Sends a specific skill | 9 | | Opcode | 154 | 10 | | Type | Fixed | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | The skill you want to send. | 18 | | [Int](/Data-Types.html#common-data-types) | The experience of that skill. | 19 | | [Byte](/Data-Types.html#common-data-types) | The level of that skill. | 20 | -------------------------------------------------------------------------------- /src/Home.md: -------------------------------------------------------------------------------- 1 | # RSWiki 2 | 3 | A source of documentation for the RSC/RS2/RS3 protocols and related systems. 4 | 5 | ## Navigation 6 | * [About](About.html) 7 | * [Rules](Rules.html) 8 | * [IRC](IRC.html) 9 | * [General disclaimer](General-disclaimer.html) 10 | * [DMCA Policy](DMCA-Policy.html) 11 | * [Privacy Policy](Privacy-policy.html) 12 | 13 | ## Game Protocol 14 | * RSC (2001 - 2004) 15 | * RS2 (2004 - 2013) 16 | * RS3 (2013 - present) 17 | 18 | ## Cache 19 | * [JAGGRAB protocol](./JAGGRAB-Protocol.html) 20 | * [Ondemand protocol](./Ondemand-Protocol.html) 21 | * [Archive format](./Archive-Format.html) 22 | -------------------------------------------------------------------------------- /src/317/317-Clear-inventory.md: -------------------------------------------------------------------------------- 1 | # Clear inventory 2 | Clears a given inventory, by setting all of its item ids to negative one and its item stacks to zero. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Clear Inventory | 8 | | Description | Used to set all of the items and item stacks in an inventory to nothing. | 9 | | Opcode | 72 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The interface ID. | 18 | -------------------------------------------------------------------------------- /src/377/377-Send-Sound.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Send 2 | Sound\|description=Sends a sound to be 3 | played.\|opcode=26\|type=Fixed\|length=5\|revision=377}} == Send Sound 4 | == 5 | 6 | === Description === Sends a sound to be played. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Short\]\] \| Unknown \#1 \|- \| \[\[Data Types\#Standard 12 | data types\|Byte\]\] \| Unknown \#2 \|- \| \[\[Data Types\#Standard data 13 | types\|Short\]\] \| Unknown \#2 \|- \|} 14 | 15 | - Needs more work. 16 | -------------------------------------------------------------------------------- /src/718-Interface.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 718\]\] {{packet\|name=Send 2 | Interface\|description=Sends an interface to be 3 | opened.\|opcode=14\|type=Fixed\|length=23\|revision=718}} == Send 4 | Interface == 5 | 6 | === Description === 7 | 8 | Opens an interface (NOT CHATBOX INTERFACES!). 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| Short \|\| The interface 13 | ID. \|- \| Int \|\| ? \|- \| Int V2 \|\| ? \|- \| Int V1 \|\| Window ID. 14 | \|- \| Byte \|\| If it is a walkable interface (1) or not (0). \|- \| 15 | Int V1 \|\| ? \|- \| Int V2 \|\| ? \|} 16 | -------------------------------------------------------------------------------- /src/317/317-Player-command.md: -------------------------------------------------------------------------------- 1 | # Player Command 2 | This packet is sent when a player types a message with the prefix '::', the message is then sent to the server and an appropriate action is taken (e.g. spawning an item). 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Player command | 8 | | Description | Sent when a player types a command in the chat box. | 9 | | Opcode | 103 | 10 | | Type | Variable Byte | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [RS String](/RS-String.html) | The command name and parameters. | 18 | -------------------------------------------------------------------------------- /src/377/377-Interface-Animation.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Interface Animation\|description=Sets a model's animation 3 | on an interface.\|opcode=2\|type=Fixed\|length=4\|revision=377}} == 4 | Interface Animation == 5 | 6 | === Description === Sets the animation for a model on an interface. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Byte 11 | Order\|Little Endian\]\] \[\[Data Types\#Standard data types\|Short\]\] 12 | \| Interface ID \|- \| \[\[Data Types\#Standard data types\|Short\]\] \| 13 | Animation ID \|- \|} 14 | -------------------------------------------------------------------------------- /src/317/317-Player-head-to-interface.md: -------------------------------------------------------------------------------- 1 | # Send player head model to an interface 2 | This packet sends a players head to an interface 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Send head model to interface. | 8 | | Description | Sends the player head model to an interface. | 9 | | Opcode | 185 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The interface ID. | 18 | -------------------------------------------------------------------------------- /src/317/317-Focus-change.md: -------------------------------------------------------------------------------- 1 | # Focus Change 2 | This packet is sent when the game client window goes in and out of focus. The payload consists of one byte that is either 1 or 0; 1 if the client is in focus and 0 if not. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Focus change | 8 | | Description | Sent when the game client window goes in and out of focus. | 9 | | Opcode | 3 | 10 | | Type | Fixed | 11 | | Length | 1 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | Whether or not the client is in focus. | 18 | -------------------------------------------------------------------------------- /src/317/317-Mage-NPC.md: -------------------------------------------------------------------------------- 1 | # Mage NPC 2 | Sent when a player attempts to use a magic attack on an NPC. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Mage NPC | 8 | | Description | Sent when a player attempts to use a magic attack on an NPC. | 9 | | Opcode | 131 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | ? | 18 | | [Little Endian](/Data-Types.html#little-endian) [Special A](/Data-Types.html#bespoke-data-types) | ? | 19 | -------------------------------------------------------------------------------- /src/317/317-Camera-movement.md: -------------------------------------------------------------------------------- 1 | # Camera Movement 2 | This packet is sent when a player moves their game camera. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Camera movement | 8 | | Description | Sent when the player moves the camera. | 9 | | Opcode | 86 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The Y coordinate of the camera. | 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The X coordinate of the camera. | 19 | -------------------------------------------------------------------------------- /src/317/317-Item-on-item.md: -------------------------------------------------------------------------------- 1 | # Item on Item 2 | This packet is sent when a player uses an item on another item. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Item on item | 8 | | Description | Sent when a player uses an item on another item. | 9 | | Opcode | 53 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The item being used on's slot. | 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item being used's slot. | 19 | -------------------------------------------------------------------------------- /src/474-Fourth-Interface-Option.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 474\]\] 2 | {{packet\|name=Fourth Interface Option\|description=Triggered when a 3 | fourth interface option has been 4 | clicked.\|opcode=3\|type=Fixed\|length=6\|revision=474}} == Fourth 5 | Interface Option == 6 | 7 | === Description === 8 | 9 | This is triggered when a fourth interface option has been clicked. 10 | 11 | === Packet Structure === {\|border=2 ! Data Type ! Description \|- \| 12 | \[\[Data Types\#Standard data types\|Int\]\] \| The button ID. \|- \| 13 | \[\[Data Types\#Standard data types\|Short\]\] \| The item container 14 | slot. \|- \|} 15 | -------------------------------------------------------------------------------- /src/317/317-Open-chatbox-interface.md: -------------------------------------------------------------------------------- 1 | # Open chatbox interface 2 | Sending this packet to the client will cause the client to open an interface over the chatbox. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Open chatbox interface | 8 | | Description | Displays an interface over the chatbox. | 9 | | Opcode | 218 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Interface ID. | 18 | -------------------------------------------------------------------------------- /src/289-Player-Dialogue-Head.md: -------------------------------------------------------------------------------- 1 | {{packet\|name=Send Player Head\|description=Sends player's head on an 2 | interface\|opcode=185\|type=Fixed\|length=5\|revision=317}} == Player 3 | Dialogue Head == 4 | 5 | === Description === 6 | 7 | This packet sends the player head to an interface. 8 | 9 | === Packet Structure === {\|border=2 ! Data Type ! Description \|- \| 10 | \[\[Data Types\#Standard data types\|Byte\]\] \| The status of the 11 | friends list. \|- \|} 12 | 13 | ==== Values ==== The below are the different values for this packet. {\| 14 | border=2 ! Value ! Response \|- \| 0 \| Loading \|- \| 1 \| Connecting 15 | \|- \| 2 \| Loaded \|- \|} 16 | -------------------------------------------------------------------------------- /src/317/317-Send-private-message.md: -------------------------------------------------------------------------------- 1 | # Send Private Message 2 | Sending a private message to another user on the server. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Sending private message | 8 | | Description | Send Message Sends Message to another user. | 9 | | Opcode | 196 | 10 | | Type | VARIABLE_SHORT | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Long](/Data-Types.html#common-data-types) | Player name. | 18 | | [Int](/Data-Types.html#common-data-types) | Global message counter. | 19 | | [Byte](/Data-Types.html#common-data-types) | Player rights. | 20 | -------------------------------------------------------------------------------- /src/377/377-Skill-Level.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Skill 2 | Level\|description=Sends a skill level to the 3 | client.\|opcode=49\|type=Fixed\|length=6\|revision=377}} == Skill Level 4 | == 5 | 6 | === Description === Sends a skill level to the client. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Byte\]\] \[\[Data Types\#Non Standard Data Types\|Special 12 | C\]\] \| Skill ID. \|- \| \[\[Data Types\#Standard data types\|Byte\]\] 13 | \| Skill level. \|- \| \[\[Data Types\#Standard data types\|Int\]\] \| 14 | Skill experience. \|- \|} 15 | -------------------------------------------------------------------------------- /src/317/317-Interface-item.md: -------------------------------------------------------------------------------- 1 | # Interface Item 2 | Displays an item model inside an interface. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Interface item | 8 | | Description | Displays an item model inside an interface. | 9 | | Opcode | 246 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | Interface ID. | 18 | | [Short](/Data-Types.html#common-data-types) | The item's model zoom. | 19 | | [Short](/Data-Types.html#common-data-types) | The item ID. | 20 | -------------------------------------------------------------------------------- /src/317/317-Skill-level.md: -------------------------------------------------------------------------------- 1 | # Skill Level 2 | This packet changes the experience and level of a given skill id. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Skill level | 8 | | Description | Changes the experience and level of a given skill id. | 9 | | Opcode | 134 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | The skill ID. | 18 | | [Middle-Endian Small Integer](/Data-Types.html#middle-endian-small-int) | The skill experience. | 19 | | [Byte](/Data-Types.html#common-data-types) | The skill level. | 20 | -------------------------------------------------------------------------------- /src/317/317-Scroll-position.md: -------------------------------------------------------------------------------- 1 | # Scroll Position 2 | This packet sets the scrollbar position of an interface. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Scroll position | 8 | | Description | Sets the scrollbar position of an interface. | 9 | | Opcode | 79 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The interface ID. | 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The position of the scrollbar. | 19 | -------------------------------------------------------------------------------- /src/377/377-Play-Ambient-Wave.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Play 2 | Ambient Wave\|description=Plays an ambient 3 | wave.\|opcode=41\|type=Fixed\|length=4\|revision=377}} == Play Ambient 4 | Wave == 5 | 6 | === Description === Plays an ambient wave. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Byte\]\] \| Packed (xxxxyyyy) coordinates of sound. \|- \| 12 | \[\[Data Types\#Standard data types\|Short\]\] \| Wave index (ID). \|- 13 | \| \[\[Data Types\#Standard data types\|Byte\]\] \| Packed (rrrruuuu) 14 | sound settings, where r is the range of the sound. \|- \|} 15 | -------------------------------------------------------------------------------- /src/317/317-Magic-on-player.md: -------------------------------------------------------------------------------- 1 | # Magic on Player 2 | This packet is sent when the player attempts to cast magic onto another. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Magic on player | 8 | | Description | This packet is send when a player attempts to cast magic on another | 9 | | Opcode | 249 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The player index. | 18 | | [Short](/Data-Types.html#common-data-types) [Little Endian](/Data-Types.html#little-endian) | The spell ID. | 19 | -------------------------------------------------------------------------------- /src/377/377-Send-Sidebar-Interface.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Set 2 | Sidebar Interface\|description=Sets the interface for the 3 | sidebar.\|opcode=10\|type=Fixed\|length=3\|revision=377}} == Interface 4 | Animation == 5 | 6 | === Description === Sets the specified interface to the specified 7 | sidebar. 8 | 9 | === Packet Structure === 10 | 11 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 12 | data types\|Byte\]\] \[\[Data Types\#Standard data types\|Special S\]\] 13 | \| Sidebar Index \|- \| \[\[Data Types\#Standard data types\|Short\]\] 14 | \[\[Data Types\#Non Standard Data Types\|Special A\]\] \| Interface ID 15 | \|- \|} 16 | -------------------------------------------------------------------------------- /src/317/317-Light-item.md: -------------------------------------------------------------------------------- 1 | # Light Item 2 | This packet is sent when a player attempts to light logs on fire. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Light item | 8 | | Description | Sent when a player attempts to light logs on fire. | 9 | | Opcode | 79 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The items Y coordinate. | 18 | | Unsigned [Short](/Data-Types.html#common-data-types) | The item ID. | 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The items X coordinate. | 20 | -------------------------------------------------------------------------------- /src/317/317-Report-player.md: -------------------------------------------------------------------------------- 1 | # Report Player 2 | This packet is sent when a player reports another player. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Report player | 8 | | Description | Sent when a player reports another player. | 9 | | Opcode | 218 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Long](/Data-Types.html#common-data-types) | The players name as a long. | 18 | | [Byte](/Data-Types.html#common-data-types) | The rule that's being reported | 19 | | [Byte](/Data-Types.html#common-data-types) | Mute for 48 hours - Sent as either 1 or 0 for a boolean client-side | 20 | -------------------------------------------------------------------------------- /src/317/317-Interface-offset.md: -------------------------------------------------------------------------------- 1 | # Interface offset 2 | Sets the offset for drawing of an interface. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Interface offset | 8 | | Description | Sets the offset for drawing of an interface | 9 | | Opcode | 70 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The X offset | 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The Y offset | 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The interface ID | 20 | -------------------------------------------------------------------------------- /src/317/317-Privacy-options.md: -------------------------------------------------------------------------------- 1 | # Privacy Options 2 | This packet is sent when a player changes their privacy options (i.e. public chat). 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Privacy options | 8 | | Description | Sent when a player changes their privacy options. | 9 | | Opcode | 95 | 10 | | Type | Fixed | 11 | | Length | 3 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | Unsigned [Byte](/Data-Types.html#common-data-types) | The public chat options. | 18 | | Unsigned [Byte](/Data-Types.html#common-data-types) | The private chat options. | 19 | | Unsigned [Byte](/Data-Types.html#common-data-types) | The trade/compete options. | 20 | -------------------------------------------------------------------------------- /src/317/317-Minimap-State.md: -------------------------------------------------------------------------------- 1 | # Minimap State 2 | This packet sets the Minimaps state, possible values are shown below. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Minimap State | 8 | | Description | Sets the state of the clients minimap. | 9 | | Opcode | 99 | 10 | | Type | Fixed | 11 | | Length | 1 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | The state. | 18 | 19 | ## Values 20 | | State | Description | 21 | |--|--| 22 | | 0 | **Active**: Clickable and viewable | 23 | | 1 | **Locked**: viewable but not clickable | 24 | | 2 | **Blacked-out**: Minimap is replaced with black background | 25 | -------------------------------------------------------------------------------- /src/377/377-Create-Static-Graphic.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Create Static Graphic\|description=Creates a static 3 | graphic.\|opcode=59\|type=Fixed\|length=6\|revision=377}} == Create 4 | Static Graphic == 5 | 6 | === Description === Creates a static graphic. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Byte\]\] \| Position (xxxxyyyy) of the graphic. \|- \| 12 | \[\[Data Types\#Standard data types\|Short\]\] \| Graphic ID. \|- \| 13 | \[\[Data Types\#Standard data types\|Byte\]\] \| Height offset. \|- \| 14 | \[\[Data Types\#Standard data types\|Short\]\] \| Placement delay. \|- 15 | \|} 16 | -------------------------------------------------------------------------------- /src/317/317-Player-Option.md: -------------------------------------------------------------------------------- 1 | # Player Option 2 | Adds an option to a player's right click context menu. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Player Option | 8 | | Description | Adds an option to a player's right click context menu. | 9 | | Opcode | 104 | 10 | | Type | Variable | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) [Special C](/Data-Types.html#bespoke-data-types) | The option position. | 18 | | [Byte](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Flag | 19 | | [String](/Data-Types.html#common-data-types) | Action text. | 20 | -------------------------------------------------------------------------------- /src/Rules.md: -------------------------------------------------------------------------------- 1 | ### Vandalism 2 | We do not allow vandalism of any kind. 3 | 4 | 5 | ### Advertising 6 | Attempting to advertise web sites which do not provide educational benefits is strictly prohibited. 7 | 8 | 9 | ### Download Links/Uploads 10 | Any link or upload that contains copywrited material (e.g. a client revision or cache archive) is strictly prohibited and will be removed 11 | 12 | 13 | ### Posting Unreliable Information 14 | The wiki is an education resource, so posting misinformed information is not optimal for learning - please avoid this. This includes edits with unclear explanations or bad information. 15 | 16 | 17 | ### Proprietary Code 18 | No server-specific code, only easily interpretable pseudo-code. 19 | -------------------------------------------------------------------------------- /src/317/317-Drop-item.md: -------------------------------------------------------------------------------- 1 | # Drop Item 2 | This packet is sent when a player wants to drop an item onto the ground. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Drop item | 8 | | Description | Sent when a player wants to drop an item onto the ground. | 9 | | Opcode | 87 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item ID. | 18 | | [Short](/Data-Types.html#common-data-types) | The frame ID. | 19 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The slot ID. | 20 | -------------------------------------------------------------------------------- /src/317/317-Equip-item.md: -------------------------------------------------------------------------------- 1 | # Equip Item 2 | This is sent when a player equips an item in-game. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Equip item | 8 | | Description | Sent when a player equips an item. | 9 | | Opcode | 41 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | Unsigned [Short](/Data-Types.html#common-data-types) | The ID of the item. | 18 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The slot of the item. | 19 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The ID of the interface. | 20 | -------------------------------------------------------------------------------- /src/317/317-Show-multi-combat.md: -------------------------------------------------------------------------------- 1 | # Show multi-combat 2 | Sending this packet to the client will make the client show the player if they are in a multi-combat zone. 3 | 4 | States: 5 | 6 | | ID | Name | 7 | |--|--| 8 | | 0 | Not in a multi-combat zone (i.e. no crossbones in bottom-right). | 9 | | 1 | In a multi-combat zone (i.e. crossbones in bottom-right). | 10 | 11 | ## Packet Details 12 | | Key | Value | 13 | |--|--| 14 | | Name | Show multi-combat | 15 | | Description | Shows the player if they are in a multi-combat zone. | 16 | | Opcode | 61 | 17 | | Type | Fixed | 18 | | Length | 1 | 19 | | Revision | 317 | 20 | 21 | ## Packet Structure 22 | | Data Type | Description | 23 | |--|--| 24 | | [Byte](/Data-Types.html#common-data-types) | The state. | 25 | -------------------------------------------------------------------------------- /src/317/317-Song-Queue.md: -------------------------------------------------------------------------------- 1 | # Song Queue 2 | This packet queue's a song to be played next. 3 | The client then proceeds to request the queued song using the on-demand protocol. 4 | 5 | ## Packet Details 6 | | Key | Value | 7 | |--|--| 8 | | Name | Song Queue | 9 | | Description | Queues a song to be played next. | 10 | | Opcode | 121 | 11 | | Type | Fixed | 12 | | Length | 4 | 13 | | Revision | 317 | 14 | 15 | ## Packet Structure 16 | | Data Type | Description | 17 | |--|--| 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Song ID | 19 | | [Little Endian](/Data-Types.html#little-endian) [Special A](/Data-Types.html#bespoke-data-types) | Previous Song ID | 20 | -------------------------------------------------------------------------------- /src/377/377-Interface-Item.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Interface Item\|description=Sends an item to an 3 | interface.\|opcode=21\|type=Fixed\|length=6\|revision=377}} == Interface 4 | Item == 5 | 6 | === Description === Sends an item to an interface. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Short\]\] \| Zoom factor. \|- \| \[\[Data Types\#Little 12 | Endian\|Little Endian\]\] \[\[Data Types\#Standard data types\|Short\]\] 13 | \| Item ID. \|- \| \[\[Data Types\#Little Endian\|Little Endian\]\] 14 | \[\[Data Types\#Standard data types\|Short\]\] \[\[Data Types\#Non 15 | Standard Data Types\|Special A\]\] \| Interface ID. \|- \|} 16 | -------------------------------------------------------------------------------- /src/377/377-Move-Camera.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Move 2 | Camera\|description=Moves the 3 | camera.\|opcode=3\|type=Fixed\|length=6\|revision=377}} == Move Camera 4 | == 5 | 6 | === Description === Moves the camera. 7 | 8 | See: void client\#updateCamera 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 13 | data types\|Byte\]\] \| Tile X coordinate. \|- \| \[\[Data 14 | Types\#Standard data types\|Byte\]\] \| Tile Y coordinate. \|- \| 15 | \[\[Data Types\#Standard data types\|Short\]\] \| Height offset. \|- \| 16 | \[\[Data Types\#Standard data types\|Byte\]\] \| Position offset. \|- \| 17 | \[\[Data Types\#Standard data types\|Byte\]\] \| Move speed. \|- \|} 18 | -------------------------------------------------------------------------------- /src/317/317-Send-message.md: -------------------------------------------------------------------------------- 1 | # Send Message 2 | Sends a server side message (e.g. 'Welcome to RuneScape'), or a trade/duel/challenge request. 3 | 4 | The format for sending such requests is: `[player name][request type]`. 5 | Where `[request type]` is one of `:duelreq:`, `:chalreq:`, or `:tradereq:`. 6 | 7 | Example: Trading a player called 'mopar': `mopar:tradereq:`. 8 | 9 | ## Packet Details 10 | | Key | Value | 11 | |--|--| 12 | | Name | Send message | 13 | | Description | Sends a server message, trade or duel request to the client's chat panel. | 14 | | Opcode | 253 | 15 | | Type | Variable Byte | 16 | | Length | N/A | 17 | | Revision | 317 | 18 | 19 | ## Packet Structure 20 | | Data Type | Description | 21 | |--|--| 22 | | [RS String](/RS-String.html) | The message. | 23 | -------------------------------------------------------------------------------- /src/377/377-Initialize-Player.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Initialize Player\|description=Sends the player's 3 | membership status and their current index on the server's player 4 | list.\|opcode=249\|type=Fixed\|length=3\|revision=377}} == Initialize 5 | Player == 6 | 7 | === Description === Sends the player's membership status and their 8 | current index on the server's player list. 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| Unsigned \[\[Data 13 | Types\#Standard data types\|Byte\]\] \| Membership flag (1 = member, 0 = 14 | free). \|- \| Unsigned \[\[Data Types\#Little Endian\|Little Endian\]\] 15 | \[\[Data Types\#Standard data types\|Short\]\] \| Player list index. \|- 16 | \|} 17 | -------------------------------------------------------------------------------- /src/317/317-Initialize-player.md: -------------------------------------------------------------------------------- 1 | # Initialize Player 2 | Sends the player membership flag and player list index. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Initialize player | 8 | | Description | Sends the player's membership status and their current index on the server's player list. | 9 | | Opcode | 249 | 10 | | Type | Fixed | 11 | | Length | 3 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Membership flag (1 = member, 0 = free). | 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Player list index. | 19 | -------------------------------------------------------------------------------- /src/377/377-Reset-Ground-Items-and-Objects.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Reset 2 | Ground Items and Objects\|description=Resets ground items in potential 3 | viewing area.\|opcode=40\|type=Fixed\|length=2\|revision=377}} == Reset 4 | Ground Items and Objects == 5 | 6 | === Description === Resets ground items in potential viewing area. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Byte\]\] \[\[Data Types\#Non Standard Data Types\|Special 12 | C\]\] \| X coordinate in potential viewing area. \|- \| \[\[Data 13 | Types\#Standard data types\|Byte\]\] \[\[Data Types\#Non Standard Data 14 | Types\|Special S\]\] \| Y coordinate in potential viewing area. \|- \|} 15 | -------------------------------------------------------------------------------- /src/377/377-Send-Ground-Item.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Send 2 | Ground Item\|description=Adds a ground item to the server. 3 | \|opcode=107\|type=Fixed\|length=5\|revision=377}} == Send Ground Item 4 | == 5 | 6 | === Description === Adds a ground item to the server. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 11 | data types\|Short\]\] \| Item ID. \|- \| \[\[Data Types\#Standard data 12 | types\|Byte\]\] \[\[Data Types\#Non Standard Data Types\|Special S\]\] 13 | \| Packed (xxxxyyyy) coordinates of the ground item. \|- \| \[\[Data 14 | Types\#Standard data types\|Short\]\] \[\[Data Types\#Non Standard Data 15 | Types\|Special A\]\] \| Stack amount of the item. \|- \|} 16 | -------------------------------------------------------------------------------- /src/317/317-NPC-head-on-interface.md: -------------------------------------------------------------------------------- 1 | # NPC head on interface 2 | Places the head of an NPC on an interface 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | NPC head on interface | 8 | | Description | Places the head of an NPC on an interface | 9 | | Opcode | 75 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The NPC ID | 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The 'slot' ID for where you wish to place the head | 19 | -------------------------------------------------------------------------------- /src/317/317-Unequip-item.md: -------------------------------------------------------------------------------- 1 | # Unequip Item 2 | This packet is sent when a player unequips an item. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Unequip item | 8 | | Description | Sent when a player unequips an item. | 9 | | Opcode | 145 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The interface ID. | 18 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The items slot ID. | 19 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item ID. | 20 | -------------------------------------------------------------------------------- /src/377/377-Inventory-Overlay.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Inventory Overlay\|description=Displays the specified 3 | interface over the specified 4 | inventory.\|opcode=128\|type=Fixed\|length=4\|revision=377}} == 5 | Inventory Overlay == 6 | 7 | === Description === Displays the specified interface over the specified 8 | inventory. 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 13 | data types\|Short\]\] \[\[Data Types\#Standard data types\|Special A\]\] 14 | \| Interface ID. \|- \| \[\[Data Types\#Byte Order\|Little Endian\]\] 15 | \[\[Data Types\#Standard data types\|Short\]\] \[\[Data Types\#Non 16 | Standard Data Types\|Special A\]\] \| Inventory interface ID \|- \|} 17 | -------------------------------------------------------------------------------- /src/317/317-Set-interface-text.md: -------------------------------------------------------------------------------- 1 | # Set Interface Text 2 | Sets the text for the specific interface. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Set interface text | 8 | | Description | Sets the text for a specified interface | 9 | | Opcode | 126 | 10 | | Type | VARIABLE_SHORT | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [RS String](/RS-String.html) | The new text for the interface | 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The interface id | 19 | 20 | ## Information 21 | I do not recommend you use this to change the text color. 22 | I refer you to [Interface Color](317-Interface-color.html) packet for the proper way to do so. 23 | -------------------------------------------------------------------------------- /src/317/317-Pickup-ground-item.md: -------------------------------------------------------------------------------- 1 | # Pickup Ground Item 2 | This packet is sent when a player clicks the "Pick Up" option on an item when its on the ground. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Pickup ground item | 8 | | Description | Sent when the player picks up an item from the ground. | 9 | | Opcode | 236 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The Y coordinate of the item. | 18 | | [Short](/Data-Types.html#common-data-types) | The item ID. | 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The X coordinate of the item. | 20 | -------------------------------------------------------------------------------- /src/317/317-Item-on-player.md: -------------------------------------------------------------------------------- 1 | # Item on Player 2 | This packet is sent when a player uses an item on another player. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Item on player | 8 | | Description | Sent when a player uses an item on another player. | 9 | | Opcode | 14 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The frame ID. | 18 | | [Short](/Data-Types.html#common-data-types) | The other players ID. | 19 | | [Short](/Data-Types.html#common-data-types) | The item ID. | 20 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The items slot ID. | 21 | -------------------------------------------------------------------------------- /src/317/317-Bank-X-items-part-1.md: -------------------------------------------------------------------------------- 1 | # Bank X Items Part-1 2 | This packet is sent when a player requests to bank an X amount of items. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Bank x items part-1 | 8 | | Description | Sent when a player requests to bank an X amount of items. | 9 | | Opcode | 135 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The items slot. | 18 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The interface ID. | 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The item ID. | 20 | -------------------------------------------------------------------------------- /src/317/317-Object-action-3.md: -------------------------------------------------------------------------------- 1 | # Object Action 3 2 | This packet is sent when a player clicks the third action available for an object. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Object action 3 | 8 | | Description | Sent when a player clicks the third action available for an object. | 9 | | Opcode | 70 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The X coordinate of the object. | 18 | | [Short](/Data-Types.html#common-data-types) | The Y coordinate of the object. | 19 | | [Big Endian](/Data-Types.html#big-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The object ID. | 20 | -------------------------------------------------------------------------------- /src/317/317-Magic-on-items.md: -------------------------------------------------------------------------------- 1 | # Magic on Items 2 | This packet is sent when a player casts magic (i.e. High Level Alchemy) on the items in their inventory. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Magic on items | 8 | | Description | Sent when a player casts magic on the items in their inventory. | 9 | | Opcode | 237 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The items slot ID. | 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item ID. | 19 | | [Short](/Data-Types.html#common-data-types) | The frame ID. | 20 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The spell ID. | 21 | -------------------------------------------------------------------------------- /src/317/317-System-update.md: -------------------------------------------------------------------------------- 1 | # System Update 2 | A timer showing how many seconds until a 'System Update' will appear in the lower left hand corner of the game screen. After the timer reaches 0 all players are disconnected and are unable to log in again until server is restarted. Players connecting will receive a message stating, "The server is being updated. Please wait 1 minute and try again." (unless stated otherwise). 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | System update | 8 | | Description | Sends how many seconds until a 'System Update.' | 9 | | Opcode | 114 | 10 | | Type | Fixed | 11 | | Length | 2 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | Time until an update. | 18 | -------------------------------------------------------------------------------- /src/317/317-Bank-10-items.md: -------------------------------------------------------------------------------- 1 | # Bank 10 Items 2 | This packet is sent when the player attempts to bank 10 of a certain item. 3 | 4 | Note: This packet is also used for selling/buying 5 of an item from a shop. 5 | 6 | ## Packet Details 7 | | Key | Value | 8 | |--|--| 9 | | Name | Bank 10 items | 10 | | Description | Sent when a player banks 10 of a certain item. | 11 | | Opcode | 43 | 12 | | Type | Fixed | 13 | | Length | 6 | 14 | | Revision | 317 | 15 | 16 | ## Packet Structure 17 | | Data Type | Description | 18 | |--|--| 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The frame ID. | 20 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item ID. | 21 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The slot ID. | 22 | -------------------------------------------------------------------------------- /src/317/317-Object-action-1.md: -------------------------------------------------------------------------------- 1 | # Object Action 1 2 | This packet is sent when a player clicks the first option of an object, such as "Cut" for trees or "Mine" for rocks. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Object action 1 | 8 | | Description | Sent when the player clicks the first option of an object. | 9 | | Opcode | 132 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The objects X coordinate. | 18 | | [Short](/Data-Types.html#common-data-types) | The objects ID. | 19 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The objects Y coordinate. | 20 | -------------------------------------------------------------------------------- /src/718-Friends-packet.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 718\]\] 2 | {{packet\|name=Friends packet\|description=Sends friend data to the 3 | client\|opcode=2\|type=VARIABLE\_SHORT\|length=-2\|revision=718}} == 4 | Friends packet == 5 | 6 | === Description === 7 | 8 | Sends friend data to the client 9 | 10 | === Packet Structure === 11 | 12 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 13 | data types\|Short\]\] \|\| If it is a warning message. \|- \| \[\[Data 14 | Types\#Standard data types\|String\]\] \|\| Display name \|- \| \[\[Data 15 | Types\#Standard data types\|String\]\] \|\| If the display name does not 16 | equal the player's username, then this sends the username \|- \| 17 | \[\[Data Types\#Standard data types\|Short\]\] \|\| The World ID \|- \| 18 | \[\[Data Types\#Standard data types\|Byte\]\] \|\| The player's rank \|} 19 | -------------------------------------------------------------------------------- /src/Censorship.md: -------------------------------------------------------------------------------- 1 | # Censorship 2 | 3 | Chat message censorship is applied client-side. 4 | 5 | Traditionally, the use of bad words does not always result in a punishment, 6 | unless if applied manually by a staff member. 7 | 8 | ## Process 9 | 10 | There are four related cache files which are loaded and used in censorship. 11 | 12 | They are as follows: 13 | 14 | | Cache file name | Purpose | 15 | |---|---| 16 | | `fragmentsenc.txt` | ? | 17 | | `badenc.txt` | Contains bad words, including variations (e.g. `fuck`, `fok`, etc.). | 18 | | `domainenc.txt` | Contains bad domain names. | 19 | | `tldlist.txt` | Contains possible top-level domain names. | 20 | 21 | When an input is received, if bad phrases are found they are replaced 22 | with a sequence of astericks. 23 | 24 | Bad phrases are either a bad word, or a combination of a bad domain name and a top-level domain name. 25 | -------------------------------------------------------------------------------- /src/317/317-Interface-model-rotation.md: -------------------------------------------------------------------------------- 1 | # Interface Color 2 | Changes the zoom and rotation of the interface id's media given. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Interface model rotation | 8 | | Description | Changes the zoom and rotation of the interface id's media given. | 9 | | Opcode | 230 | 10 | | Type | Fixed | 11 | | Length | 8 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The zoom. | 18 | | [Short](/Data-Types.html#common-data-types) | The interface id. | 19 | | [Short](/Data-Types.html#common-data-types) | The rotation1. | 20 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The rotation2. | 21 | -------------------------------------------------------------------------------- /src/317/317-Bank-all-items.md: -------------------------------------------------------------------------------- 1 | # Bank 10 Items 2 | This packet is sent when a player banks all of a certain item they have in their inventory. 3 | 4 | Note: This packet is also used for selling/buying 10 items at a shop. 5 | 6 | ## Packet Details 7 | | Key | Value | 8 | |--|--| 9 | | Name | Bank all items | 10 | | Description | Sent when a player banks all of a certain item they have in their inventory. | 11 | | Opcode | 129 | 12 | | Type | Fixed | 13 | | Length | 6 | 14 | | Revision | 317 | 15 | 16 | ## Packet Structure 17 | | Data Type | Description | 18 | |--|--| 19 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The items slot ID. | 20 | | Unsigned [Short](/Data-Types.html#common-data-types) | The interface ID. | 21 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item ID. | 22 | -------------------------------------------------------------------------------- /src/317/317-Flash-sidebar.md: -------------------------------------------------------------------------------- 1 | # Flash sidebar 2 | This packet causes a sidebar icon to start flashing. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Flash sidebar | 8 | | Description | Causes a sidebar icon to start flashing. | 9 | | Opcode | 24 | 10 | | Type | Fixed | 11 | | Length | 1 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) [Special S](/Data-Types.html#bespoke-data-types) | The sidebar ID. | 18 | 19 | ## Values 20 | | Sidebar ID | Icon | 21 | |--|--| 22 | | 0 | Attack type | 23 | | -1 | Stats | 24 | | -2 | Quests | 25 | | -3 | Inventory | 26 | | -4 | Wearing | 27 | | -5 | Prayer | 28 | | -6 | Magic | 29 | | -7 | *EMPTY* | 30 | | -8 | Friends list | 31 | | -9 | Ignore list | 32 | | -10 | Log out | 33 | | -11 | Settings | 34 | | -12 | Emotes | 35 | | -13 | Music | 36 | -------------------------------------------------------------------------------- /src/317/317-Item-action-1.md: -------------------------------------------------------------------------------- 1 | # Item Action 1 2 | This packet is sent when a player clicks the first option of an item, such as "Bury" for bones or "Eat" for food. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Item action 1 | 8 | | Description | Sent when the player clicks the first option of an item. | 9 | | Opcode | 122 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The frame ID. | 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The slot the item is in. | 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The ID of the item. | 20 | -------------------------------------------------------------------------------- /src/377/377-Camera-Shake.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Camera Shake\|description=Set camera shake 3 | parameters.\|opcode=67\|type=Fixed\|length=4\|revision=377}} == Camera 4 | Shake == 5 | 6 | === Description === Set camera shake parameters. It may be worth reading 7 | about Sine Waves \[http://en.wikipedia.org/wiki/Sine\_wave\]. 8 | 9 | === Packet Structure === 10 | 11 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Standard 12 | data types\|Byte\]\] \| The index of the shake parameter to modify. \|- 13 | \| \[\[Data Types\#Standard data types\|Byte\]\] \| The range of the 14 | shake randomness. \|- \| \[\[Data Types\#Standard data types\|Byte\]\] 15 | \| The amplitude (maximum displacement from 0) of the shake. \|- \| 16 | \[\[Data Types\#Standard data types\|Byte\]\] \| The phase (where in its 17 | cycle the oscillation is at t = 0) of the shake. \|- \|} 18 | -------------------------------------------------------------------------------- /src/357-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RS2\]\] == '''Login Protocol''' == 2 | 3 | The Login protocol is identical to the \[\[317 Protocol\#Login Protocol 4 | Overview\|317 Login protocol\]\]. 5 | 6 | == Game Protocol == 7 | 8 | === Server -\> Client Packets === {\| border=2 \|- ! Opcode ! Type ! 9 | Length (bytes) ! Name ! Description \|- ! 31 ! VARIABLE\_BYTE ! N/A ! 10 | \[\[357 Send Message\|Send Message\]\] ! Sends a message to the client, 11 | such as 'Welcome to RuneScape'. \|- ! 96 ! VARIBLE\_BYTE ! N/A ! \[\[357 12 | Send Inventory\|Send Inventory\]\] ! Sends the players inventory to the 13 | client. \|- ! 121 ! FIXED ! 4 ! \[\[357 Load Map Region\|Load Map 14 | Region\]\] ! Tells the client to load a map region depending on the 15 | region's X and Y coordinates. \|- ! 163 ! FIXED ! 3 ! \[\[357 Send 16 | Sidebar Interface\|Send Sidebar Interface\]\] ! Assigns an interface to 17 | one of the tabs in the game sidebar. \|-} 18 | -------------------------------------------------------------------------------- /src/317/317-Inventory-overlay.md: -------------------------------------------------------------------------------- 1 | # Child Frame 2 | This packet overlays an interface in the inventory area. This is used in trading and staking. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Inventory Overlay | 8 | | Description | Overlays an interface on the inventory | 9 | | Opcode | 248 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The interface to open. | 18 | | [Short](/Data-Types.html#common-data-types) | The interface to overlay the inventory area. | 19 | 20 | ## Example 21 | `sendFrame248(3323, 3321);` 22 | 23 | That will set the open interface to interface 3323, which is the trade interface. 24 | With the inventory overlay interface as 3321, which is an inventory type interface with offer actions. 25 | -------------------------------------------------------------------------------- /src/317/317-Object-action-2.md: -------------------------------------------------------------------------------- 1 | # Object action 2 2 | This packet is sent when a player clicks the second option available of an object, such as "Prospect" for rocks. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Object action 2 | 8 | | Description | Sent when the player clicks the second option available for an an object. | 9 | | Opcode | 252 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The objects ID. | 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The objects Y coordinate. | 19 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The objects X coordinate. | 20 | -------------------------------------------------------------------------------- /src/317/317-Move-item.md: -------------------------------------------------------------------------------- 1 | # Move Item 2 | This packet is sent when a player moves an item from one slot to another. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Move item | 8 | | Description | Sent when the player moves an item from one slot to another. | 9 | | Opcode | 214 | 10 | | Type | Fixed | 11 | | Length | 7 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The frame ID. | 18 | | [Byte](/Data-Types.html#common-data-types) | Insert mode. | 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Starting slot. | 20 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | New slot. | 21 | -------------------------------------------------------------------------------- /src/IRC.md: -------------------------------------------------------------------------------- 1 | Want to chat with RSWiki members? Discuss anything and everything? Join our IRC network! 2 | 3 | ### Connection Information 4 | Join from a browser here: 5 | [https://www.moparisthebest.com/irc/](https://www.moparisthebest.com/irc/) 6 | 7 | Or from a regular client with these details: 8 | Server: irc.moparisthebest.com 9 | Port: 6697 with TLS/SSL 10 | Channel: #mopar 11 | 12 | ### How To Guide (New Users) 13 | #### Important commands 14 | * Register your nickname - /msg nickserv register [YourPassword] [YourEmail] 15 | * Identifying yourself (logging in) - /msg nickserv identify [YourPassword] 16 | * Joining a channel - /msg #[channel name] 17 | 18 | #### Recommended IRC clients 19 | * [Hexchat](https://hexchat.github.io/) 20 | * [irssi](http://www.irssi.org/) 21 | * [Quassel](http://quassel-irc.org/) 22 | * [Weechat](https://weechat.org/) 23 | * [More...](https://en.wikipedia.org/wiki/Comparison_of_Internet_Relay_Chat_clients) -------------------------------------------------------------------------------- /src/317/317-Alternate-item-option-2.md: -------------------------------------------------------------------------------- 1 | # Alternate Item Option 2 2 | This packet is sent when a player clicks the alternate second option of an item. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Alternate Item Option 2 | 8 | | Description | Sent when the player clicks the alternate second option of an item. | 9 | | Opcode | 16 | 10 | | Type | Fixed | 11 | | Length | 6 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The ID of the item. | 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The slot the item is in. | 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The frame ID. | 20 | -------------------------------------------------------------------------------- /src/317/317-Bank-5-items.md: -------------------------------------------------------------------------------- 1 | # Bank 5 Items 2 | This packet is sent when a player attempts to bank 5 of a certain item. 3 | 4 | Note: This packet is also used for buying/selling 1 of an item from a shop. 5 | 6 | ## Packet Details 7 | | Key | Value | 8 | |--|--| 9 | | Name | Bank 5 items | 10 | | Description | Sent when a player attempts to bank 5 of a certain item. | 11 | | Opcode | 117 | 12 | | Type | Fixed | 13 | | Length | 6 | 14 | | Revision | 317 | 15 | 16 | ## Packet Structure 17 | | Data Type | Description | 18 | |--|--| 19 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The frame ID. | 20 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item ID. | 21 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The slot ID. | 22 | -------------------------------------------------------------------------------- /src/317/317-Interface-color.md: -------------------------------------------------------------------------------- 1 | # Interface Color 2 | This packet changes the color of an interface that is text. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Interface color | 8 | | Description | This packet changes the color of an interface that is text. | 9 | | Opcode | 122 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The interface ID. | 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The color. | 19 | 20 | ## Information 21 | You use this packet to change the color of text in an interface. 22 | 23 | | Color | Code | 24 | |--|--| 25 | | Green | 0x3366 | 26 | | Yellow | 0x33FF66 | 27 | | Red | 0x6000 | 28 | -------------------------------------------------------------------------------- /src/317/317-Open-welcome-screen.md: -------------------------------------------------------------------------------- 1 | # Open Welcome Screen 2 | This packet displays the welcome screen. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Open welcome screen | 8 | | Description | Displays the welcome screen. | 9 | | Opcode | 176 | 10 | | Type | Fixed | 11 | | Length | 10 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) [Special C](/Data-Types.html#bespoke-data-types) | Days since last recovery change (200 for not yet set, 201 for members server). | 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Number of unread messages. | 19 | | [Byte](/Data-Types.html#common-data-types) | Member warning (1 for member, 0 for non-member). | 20 | | [Middle-Endian Big Integer](/Data-Types.html#middle-endian-big-integer) | Last logged IP. | 21 | | [Short](/Data-Types.html#common-data-types) | Last logged successful log-in. | 22 | -------------------------------------------------------------------------------- /src/317/317-Send-add-ignore.md: -------------------------------------------------------------------------------- 1 | # Send ignored users 2 | Sends the IDs of all the users that this player has in their ignore. 3 | 4 | Note: By looking at the rest of the 317 protocol, there doesn't seem to be a way to change the list dynamically. 5 | It seems as though that whenever the player decides to add or remove a player from their list, it must send all the values again. 6 | 7 | ## Packet Details 8 | | Key | Value | 9 | |--|--| 10 | | Name | Send ignored users | 11 | | Description | Sends a list of all the ignored player IDs | 12 | | Opcode | 214 | 13 | | Type | VARIABLE_SHORT | 14 | | Length | N/A | 15 | | Revision | 317 | 16 | 17 | ## Packet Structure 18 | | Data Type | Description | 19 | |--|--| 20 | | Long block (see blow) | Player name | 21 | 22 | ## Long block 23 | This packet has a slightly different structure than the other packets. 24 | 25 | ```java 26 | int entries = packetSize / 8; 27 | 28 | for (int i = 0; i < entries; i++) { 29 | ignoreList[i] = stream.readLong(); 30 | } 31 | ``` 32 | -------------------------------------------------------------------------------- /src/Ondemand-Protocol.md: -------------------------------------------------------------------------------- 1 | # Ondemand protocol 2 | 3 | The Ondemand protocol is used to stream updates to the cache. 4 | The client knows which files to update from the CRC file downloaded 5 | using the [JAGGRAB Protocol](./JAGGRAB-Protocol.html). 6 | 7 | ## Request format 8 | 9 | The client first authenticates as an ondemand client by using the opcode 10 | '15' (as opposed to the game, which uses the type '14'). 11 | 12 | The format of the request is: 13 | 14 | ``` 15 | unsigned byte cacheId; 16 | unsigned short fileId; 17 | unsigned byte priority; 18 | ``` 19 | 20 | Furthermore, there can be multiple requests per session. 21 | 22 | ## Response format 23 | 24 | The response is sent in blocks. The maximum size of a block is 500 25 | bytes. Smaller blocks (e.g. towards the end of a file) are permitted. 26 | 27 | The format of a block is: 28 | ``` 29 | unsigned byte cacheId; 30 | unsigned short fileId; 31 | unsigned short fileSize; 32 | unsigned byte blockNumber; 33 | unsigned byte[] blockData; 34 | ``` 35 | -------------------------------------------------------------------------------- /src/317/317-Create-Projectile.md: -------------------------------------------------------------------------------- 1 | # Create Projectile 2 | Creates a projectile. 3 | 4 | ## Packet Structure 5 | | Data Type | Description | 6 | |--|--| 7 | | [Byte](/Data-Types.html#common-data-types) | Position offset | 8 | | [Byte](/Data-Types.html#common-data-types) | Second X offset | 9 | | [Byte](/Data-Types.html#common-data-types) | Second Y offset | 10 | | [Short](/Data-Types.html#common-data-types) | Target | 11 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | Graphic ID | 12 | | [Byte](/Data-Types.html#common-data-types) | Starting height | 13 | | [Byte](/Data-Types.html#common-data-types) | Ending height | 14 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | Starting time | 15 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | Speed | 16 | | [Byte](/Data-Types.html#common-data-types) | Initial slope | 17 | | [Byte](/Data-Types.html#common-data-types) | Initial distance from source | 18 | -------------------------------------------------------------------------------- /src/317/317-Force-client-setting.md: -------------------------------------------------------------------------------- 1 | # Force Client Setting 2 | The client stores various user settings in an array, the default values are also stored in another array. This packet changes the default value for a setting and its current value to the one given. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Force client setting | 8 | | Description | Forcefully alters a client setting value and default value to some supplied value. | 9 | | Opcode | 36 | 10 | | Type | Fixed | 11 | | Length | 3 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Little Endian](/Data-Types.html#little-endian) | Setting ID number. | 18 | | [Byte](/Data-Types.html#common-data-types) | New value (and default value) for the setting. | 19 | 20 | ## Other Information 21 | Opcode 87 (length 6) is extremely similar in structure, but the new value is received as an Middle Endian Small Int. 22 | This suggests its for use with bigger setting values. 23 | -------------------------------------------------------------------------------- /src/317/317-Update-item-container.md: -------------------------------------------------------------------------------- 1 | # Update item container 2 | Updates the items in a given interface component. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Update item container | 8 | | Description | Updates items in an interface component. | 9 | | Opcode | 53 | 10 | | Type | VARIABLE_SHORT | 11 | | Length | N/A | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | Unsigned [Short](/Data-Types.html#common-data-types) | Interface ID. | 18 | | Unsigned [Short](/Data-Types.html#common-data-types) | Amount of items. | 19 | 20 | The rest in pseudo-code: 21 | 22 | ```java 23 | for (i = 0; i < amt_of_items; i++) { 24 | item_amount = read_u_byte(); // Item Amount: U Byte 25 | 26 | if (item_amount == 255) 27 | item_amount = read_int_me_b(); // Item Amount (if entered as 255 previously - to allow bigger amounts than 254): Middle-Endian Big Integer 28 | 29 | item_id = read_u_short_le_a(); // Item ID: U Short Little Endian Special A 30 | } 31 | ``` 32 | -------------------------------------------------------------------------------- /src/317/317-Load-map-region.md: -------------------------------------------------------------------------------- 1 | # Load Map Region 2 | Makes the client load the specified map region. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Load map region | 8 | | Description | Makes the client load the specified map region. | 9 | | Opcode | 73 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | Region X coordinate (absolute X / 8) plus 6. | 18 | | [Short](/Data-Types.html#common-data-types) | Region Y coordinate (absolute Y / 8) plus 6. | 19 | 20 | ## Other Information 21 | There are various loops/arrays within the map region loading functionality of the client which have been misunderstood by many. 22 | 23 | | Loop type | Description | 24 | |--|--| 25 | | 104 x 104 | Maximum size of the client's load area | 26 | | 8 x 8 | Load blocks to speed up loading NPCs, Items and Objects | 27 | | 13 x 13 | Number of load blocks to load | 28 | -------------------------------------------------------------------------------- /src/317/317-Item-on-object.md: -------------------------------------------------------------------------------- 1 | # Item on Object 2 | This packet is sent when a player uses an item on object. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Item on object | 8 | | Description | Sent when a player uses an item on an objet. | 9 | | Opcode | 192 | 10 | | Type | Fixed | 11 | | Length | 12 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The frame ID. | 18 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The object ID. | 19 | | [Big Endian](/Data-Types.html#big-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The objects Y coordinate. | 20 | | [Big Endian](/Data-Types.html#big-endian) [Short](/Data-Types.html#common-data-types) | The items slot ID. | 21 | | [Big Endian](/Data-Types.html#big-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The objects X coordinate. | 22 | | [Short](/Data-Types.html#common-data-types) | The item ID. | 23 | -------------------------------------------------------------------------------- /src/ISAAC-cipher.md: -------------------------------------------------------------------------------- 1 | # ISAAC cipher 2 | 3 | ISAAC is a cryptographically secure pseudorandom number generator, and a stream cipher designed by Robert J. Jenkins Jr (see [ISAAC](http://burtleburtle.net/bob/rand/isaacafa.html)). 4 | 5 | You can find the standard Java implementation used [here](https://github.com/PureCS/rs317-client/blob/master/src/com/runescape/client/io/ISAACCipher.java). 6 | 7 | ## ISAAC instance creation 8 | When a client logs into the server, two instances of ISAAC are created, 9 | and the generated seeds are transmitted between them. 10 | One instance is for encryption, and one for decryption. 11 | 12 | The seed is comprised of 128-bits, half is generated by the client, and 13 | half by the server. 14 | This is to ensure that no individual entity has entire control of 15 | the key generation process. 16 | 17 | ## Use in the client 18 | ISAAC is used to encrypt and decrypt packet opcodes before transmission, to make packet manipulation harder. 19 | 20 | When a packet is sent, its opcode becomes the original opcode added to the generated ISAAC opcode from the encryption instance. 21 | 22 | The packet opcode is decrypted analogously on the server. 23 | -------------------------------------------------------------------------------- /src/317/317-Send-sidebar-interface.md: -------------------------------------------------------------------------------- 1 | # Send Sidebar Interface 2 | This packet assigns an interface to one of the tabs in the game sidebar. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Send sidebar interface | 8 | | Description | Assigns an interface to on of the tabs in the game sidebar. | 9 | | Opcode | 71 | 10 | | Type | Fixed | 11 | | Length | 3 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Short](/Data-Types.html#common-data-types) | The sidebar ID. | 18 | | [Byte](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The interface ID. | 19 | 20 | ## Values 21 | The below are the different values for this packet. 22 | 23 | | Value | Icon | Norm. ID | 24 | |--|--|--| 25 | | 0 | Attack type | 2433 | 26 | | 1 | Stats | 3917 | 27 | | 2 | Quests | 638 | 28 | | 3 | Inventory | 3213 | 29 | | 4 | Wearing | 1644 | 30 | | 5 | Prayer | 5608 | 31 | | 6 | Magic | 1151 | 32 | | 7 | *EMPTY* | N/A | 33 | | 8 | Friends list | 5065 | 34 | | 9 | Ignore list | 5715 | 35 | | 10 | Log out | 2449 | 36 | | 11 | Settings | 4445 | 37 | | 12 | Emotes | 147 | 38 | | 13 | Music | 6299 | 39 | -------------------------------------------------------------------------------- /src/317/317-Item-on-floor.md: -------------------------------------------------------------------------------- 1 | # Description 2 | This packet is sent when a player uses an item on another item thats on the floor. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Item on floor | 8 | | Description | Sent when a player uses an item on another item thats on the floor. | 9 | | Opcode | 25 | 10 | | Type | Fixed | 11 | | Length | 10 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) | The interface ID. | 18 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The item being used ID. | 19 | | [Short](/Data-Types.html#common-data-types) | The floor items ID. | 20 | | Unsigned [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The Y coordinate of the item. | 21 | | Unsigned [Little Endian](/Data-Types.html#little-endian) [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The items slot ID. | 22 | | [Short](/Data-Types.html#common-data-types) | The X coordinate of the item. | 23 | -------------------------------------------------------------------------------- /src/About.md: -------------------------------------------------------------------------------- 1 | Many of you may recall Graham and Blakeman's runewiki project - it 2 | contained very useful information about numerous client revision 3 | protocols and other resources. Unfortunately, the wiki and any backups 4 | of the database have been lost for over two years now (and there are no 5 | cached copies floating around). Because of this, we've decided (and have 6 | started) embarking on the journey of re-creating the wiki. 7 | 8 | In regards to the aforementioned, backups have (and are continuously) 9 | being made of the database. 10 | Currently, the majority of the information covered is based 11 | on the #317 and #377 revisions. 12 | Currently, the majority of the information covered is based on the 13 | '''\#317''' Protocol, '''JAGGRAB''' Protocol, '''Ondemand''' Protocol, 14 | '''Cache Archive Format''','''RS Data Types''', and'''\#202''' Protocol. 15 | 16 | The format of the wiki is fairly laid out, so it will be quite easy to 17 | expand on certain topics. If anyone has any information on the other 18 | commonly used client revisions (or perhaps a new one) feel free to 19 | contribute. 20 | 21 | RSWiki is hosted and maintained by the [moparisthebest](https://forum.moparisthebest.com/) community. 22 | -------------------------------------------------------------------------------- /src/464-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RS2\]\] 2 | 3 | Currently under development. 4 | 5 | == '''Packet structure''' == When the client sends a packet to the 6 | server, the first byte encapsulates its opcode. This specific opcode is 7 | encrypted with a value generated by the ISAAC PRNG seeded with a 8 | dynamically server generated key during the login block. The server 9 | decrypts it and associates the opcode to the packet's respective 10 | predefined size. If the packet does not contain a fixed size, the opcode 11 | will be followed by either a byte or a word - varying per packet - for 12 | its proper size. This is then followed by the payload. 13 | 14 | == '''Login''' == Blank at the moment. 15 | 16 | =='''Game Protocol'''== 17 | 18 | ===Server -\> Client Packets=== 19 | 20 | { 21 | --- 22 | 23 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 163 \| 24 | Fixed \| 1 \| \[\[317 Run Energy\|Run Energy\]\] \| Sends the players 25 | run energy percentage. \|- \|} 26 | 27 | ===Client -\> Server Packets=== 28 | 29 | { 30 | --- 31 | 32 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 49 \| 33 | VARIABLE BYTE \| 13 \| \[\[464 Character Design\|Character Design\]\] \| 34 | Sent when accepting the player's appearance on the design screen. \|- \| 35 | 115 \| VARIABLE BYTE \| N/A \| \[\[464 Chat\|Chat\]\] \| Sent when the 36 | player enters a chat message. \|- \|} 37 | -------------------------------------------------------------------------------- /src/468-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RS2\]\] 2 | 3 | Currently under development. 4 | 5 | == '''Packet structure''' == When the client sends a packet to the 6 | server, the first byte encapsulates its opcode. This specific opcode is 7 | encrypted with a value generated by the ISAAC PRNG seeded with a 8 | dynamically server generated key during the login block. The server 9 | decrypts it and associates the opcode to the packet's respective 10 | predefined size. If the packet does not contain a fixed size, the opcode 11 | will be followed by either a byte or a word - varying per packet - for 12 | its proper size. This is then followed by the payload. 13 | 14 | == '''Login''' == Blank at the moment. 15 | 16 | =='''Game Protocol'''== 17 | 18 | ===Server -\> Client Packets=== 19 | 20 | { 21 | --- 22 | 23 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 147 \| 24 | DataType.SHORT, DataOrder.LITTLE, \| 1 \| \[\[317 Run Energy\|Run 25 | Energy\]\] \| Sends the Mapregion \|- \|} 26 | 27 | ===Client -\> Server Packets=== 28 | 29 | { 30 | --- 31 | 32 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 49 \| 33 | VARIABLE BYTE \| 13 \| \[\[464 Character Design\|Character Design\]\] \| 34 | Sent when accepting the player's appearance on the design screen. \|- \| 35 | 115 \| VARIABLE BYTE \| N/A \| \[\[464 Chat\|Chat\]\] \| Sent when the 36 | player enters a chat message. \|- \|} 37 | -------------------------------------------------------------------------------- /src/289-Construct-Map-Region.md: -------------------------------------------------------------------------------- 1 | {{packet\|name=Construct Map Region\|description=Constructs the map 2 | region\|opcode=241\|type=Variable Short\|length=N/A\|revision=317}} == 3 | Construct Map Region == 4 | 5 | === Description === 6 | 7 | This packet constructs the map region. 8 | 9 | === Packet Structure === {\|border=2 ! Data Type ! Description \|- \| 10 | \[\[Data Types\#Standard data types\|Additional Short\]\] \| The players 11 | region y plus 6. \|- \| \[\[Data Types\#Standard data types\|Short\]\] 12 | \| The players region x plus 6. \|- \|} 13 | 14 | === Other Information === 15 | 16 | After the region y is sent, you need to initialize the bit access. Then, 17 | loop through the z (which can only go up to 3). Still in the for-loop, 18 | you need to go through the x's (up to 12). Then, loop through the y's 19 | (up to 12). 20 | 21 | All of this is in the all three for-loops! 22 | 23 | Step 1: Then you'll get the tile of x, y, and z. 24 | 25 | Step 2: Then you need to send the bits 1 and (if tile is null) 1 26 | otherwise, 0. 27 | 28 | Step 3: Check if the tile is not null. Within this if-statement, you put 29 | these bits... 30 | 31 | {\|border=2 ! Method \|- \| putBits(26, tile.getX() \<\< 14 \| 32 | tile.getY() \<\< 3 \| tile.getZ() \<\< 24 \| tile.getRotation() \<\< 1) 33 | \|- \|} 34 | 35 | Out of the for-loops! 36 | 37 | Step 1: Finish the bit access and send the region x. 38 | 39 | Done. 40 | -------------------------------------------------------------------------------- /src/634-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RS2\]\] 2 | 3 | == '''Packet structure''' == When the client sends a packet to the 4 | server, the first byte encapsulates its opcode. This specific opcode is 5 | encrypted with a value generated by the ISAAC PRNG seeded with a 6 | dynamically server generated key during the login block. The server 7 | decrypts it and associates the opcode to the packet's respective 8 | predefined size. If the packet does not contain a fixed size, the opcode 9 | will be followed by either a byte or a word - varying per packet - for 10 | its proper size. This is then followed by the payload. 11 | 12 | An addition to modern emulation protocols was the addition to allow 13 | packets with an opcode of a word to be deciphered from the buffer. This 14 | is done by taking the first two ISAAC PRNG seeds; each byte from the 15 | buffer at the current offset is deciphered sequentially. If the first 16 | byte deciphered is less than the maximum of a signed byte then the 17 | packet is assumed to be byte length, otherwise it's considered to be 18 | word length. 19 | 20 | == '''Login''' == Every connection to the main 'gateway' server sends a 21 | single byte of data, mostly well known as the connection type. The 22 | connection type tells the main server which type of connection you wish 23 | to initiate. The old engine list consists of: 24 | 25 |
26 | Needs documentation on how to login
27 | 
28 | -------------------------------------------------------------------------------- /src/317/317-Design-screen.md: -------------------------------------------------------------------------------- 1 | # Design Screen 2 | This packet is sent when a player is choosing their character design options. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Design screen | 8 | | Description | Sent when a player is choosing their character design options. | 9 | | Opcode | 101 | 10 | | Type | Fixed | 11 | | Length | 13 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | The players gender. | 18 | | [Byte](/Data-Types.html#common-data-types) | The players head model. | 19 | | [Byte](/Data-Types.html#common-data-types) | The players beard model. | 20 | | [Byte](/Data-Types.html#common-data-types) | The players torso model. | 21 | | [Byte](/Data-Types.html#common-data-types) | The players arm model. | 22 | | [Byte](/Data-Types.html#common-data-types) | The players hand model. | 23 | | [Byte](/Data-Types.html#common-data-types) | The players leg model | 24 | | [Byte](/Data-Types.html#common-data-types) | The players foot model. | 25 | | [Byte](/Data-Types.html#common-data-types) | The players hair color. | 26 | | [Byte](/Data-Types.html#common-data-types) | The players torso color. | 27 | | [Byte](/Data-Types.html#common-data-types) | The players leg color. | 28 | | [Byte](/Data-Types.html#common-data-types) | The players foot color. | 29 | | [Byte](/Data-Types.html#common-data-types) | The players skin color. | 30 | -------------------------------------------------------------------------------- /src/194-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 194\]\] \[\[Category RS2\]\] 2 | 3 | Just in case somebody cares about this. 4 | 5 | == '''Packet structure''' == ? 6 | 7 | == '''Login''' == ? 8 | 9 | == '''Game Protocol''' == 10 | 11 | ===Server -\> Client Packets=== 12 | 13 | { 14 | --- 15 | 16 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 137 \| 17 | FIXED \| 2 \| \[\[194 Show interface\|Show interface\]\] \| Displays a 18 | normal interface. \|- \| 164 \| VARIABLE\_BYTE \| N/A \| \[\[194 Send 19 | message\|Send message\]\] \| Sends a server message (e.g. 'Welcome to 20 | RuneScape') or trade/duel request. \|- \| 192 \| FIXED \| 0 \| \[\[194 21 | Logout\|Logout\]\] \| Disconnects the client from the server. \|- \| 206 22 | \| VARIABLE\_BYTE \| N/A \| \[\[194 Set MIDI\|Set MIDI\]\] \| Sets the 23 | current song playing on the client. \|- \| 210 \| FIXED \| 3 \| \[\[194 24 | Send sidebar interface\|Send sidebar interface\]\] \| Assigns an 25 | interface to one of the tabs in the game sidebar. \|- \| 240 \| FIXED \| 26 | 0 \| \[\[194 Clear screen\|Clear screen\]\] \| Clears the screen of all 27 | open interfaces. \|- \|} 28 | 29 | ===Client -\> Server Packets=== 30 | 31 | { 32 | --- 33 | 34 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 54 \| 35 | VARIABLE\_BYTE \| N/A \| Send Chat Message \| Sends a chat message to 36 | the server. \|- \| 237 \| VARIABLE\_BYTE \| N/A \| Send Command \| Sends 37 | a command (any message prefixed with ::) to the server. \|- \|} 38 | -------------------------------------------------------------------------------- /src/317/317-Construct-map-region.md: -------------------------------------------------------------------------------- 1 | # Construct Map Region 2 | The construct map region packet sends a dynamic map region that is constructed by using groups of 8x8 tiles. 3 | It is generally used for instanced areas, such as fight caves, and in later revisions, player owned houses. 4 | 5 | ## Packet Details 6 | | Key | Value | 7 | |--|--| 8 | | Name | Construct map region | 9 | | Description | Constructs a new map region from a palette of 8x8 tiles. | 10 | | Opcode | 241 | 11 | | Type | Variable Short | 12 | | Length | N/A | 13 | | Revision | 317 | 14 | 15 | ## Packet Structure 16 | | Data Type | Description | 17 | |--|--| 18 | | [Short](/Data-Types.html#common-data-types) [Special A](/Data-Types.html#bespoke-data-types) | The region Y coordinate (absolute Y coordinate / 8), plus 6. | 19 | | Bit block | See below. | 20 | | [Short](/Data-Types.html#common-data-types) | The region X coordinate (absolute X coordinate / 8), plus 6. | 21 | 22 | ## Bit block 23 | The bit block contains the 'palette' of map regions to make up the new region. 24 | 25 | A loop is used to construct it, as follows: 26 | 27 | ```java 28 | for (int z = 0; z < 4; z++) { 29 | for(int x = 0; x < 13; x++) { 30 | for(int y = 0; y < 13; y++) { 31 | // data for this region 32 | } 33 | } 34 | } 35 | ``` 36 | 37 | The individual format in each iteration of the loop is: 38 | * 1 bit - set to 0 to indicate to display nothing, 1 to display a region 39 | * 26 bits - if the flag above is set to 1: `region_x << 14 | region_y << 3` 40 | -------------------------------------------------------------------------------- /src/377/377-Construct-Map-Region.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] 2 | {{packet\|name=Construct Map Region\|description=Creates a map 3 | region.\|opcode=53\|type=Variable Short\|length=N/A\|revision=377}} == 4 | Interface Animation == 5 | 6 | === Description === Sets the animation for a model on an interface. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Non 11 | Standard Data Types\|Big Endian\]\] \[\[Data Types\#Standard data 12 | types\|Short\]\] \[\[Data Types\#Non Standard Data Types\|Special A\]\] 13 | \| Map Region Y (absolute Y coordinate / 8 + 6) \|- \| \[\[Data 14 | Types\#Standard data types\|Bit Block\]\] \| 1 bit (0 or 1) to decide if 15 | a tile exists. 26 bits for data about the tile (only if it exists) \|- 16 | \| \[\[Data Types\#Non Standard Data Types\|Big Endian\]\] \[\[Data 17 | Types\#Standard data types\|Short\]\] \[\[Data Types\#Non Standard Data 18 | Types\|Special A\]\] \| Map Region X (absolute X coordinate / 8 + 6) \|- 19 | \|} 20 | 21 | === Information === 22 | 23 | If the tile exists then a 1 gets written to the output stream as a 1 24 | otherwise a zero gets written to the stream. 25 | 26 | If the tile does exist then you would follow that 1 bit with 26 bits of 27 | information about the tile. 28 | 29 | int info = inStream.readBits(26); int heightLevel = info \>\> 24 & 3; 30 | int rotation = info \>\> 1 & 3; int regionX = info \>\> 14 & 0x3ff; int 31 | regionY = info \>\> 3 & 0x7ff; 32 | 33 | === Implementation === 34 | 35 | for(int z = 0; z \< 4; z++) { for(int x = 0; x \< 13; x++) { for(int y = 36 | 0; y \< 13; y++) { outStream.writeBit(1, tileExists ? 1 : 0); 37 | if(tileExists) outStream.writeBits(26, TILE\_INFORMATION); } } } 38 | -------------------------------------------------------------------------------- /src/668-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RS2\]\] 2 | 3 | == '''Packet structure''' == When the client sends a packet to the 4 | server, the first byte encapsulates its opcode. This specific opcode is 5 | encrypted with a value generated by the ISAAC PRNG seeded with a 6 | dynamically server generated key during the login block. The server 7 | decrypts it and associates the opcode to the packet's respective 8 | predefined size. If the packet does not contain a fixed size, the opcode 9 | will be followed by either a byte or a word - varying per packet - for 10 | its proper size. This is then followed by the payload. 11 | 12 | == '''Login''' == Every connection to the main 'gateway' server sends a 13 | single byte of data, mostly well known as the connection type. The 14 | connection type tells the main server which type of connection you wish 15 | to initiate. The old engine list consists of: 16 | 17 | - Login initiation - connection type 14 18 | - JAGGRAB - connection type 15 19 | - Create account - connection type 28 20 | - Facebook login - connection type 29 21 | - Potentially more... 22 | 23 |
24 | Needs documentation on how to login
25 | 
26 | ===Server -\> Client Packets=== {\| border=2 \|- ! Opcode ! Type ! 27 | Length (bytes) ! Name ! Description \|- \| 69 \| VARIABLE\_SHORT \| - \| 28 | \[\[668 System update\|System update\]\] \| Displays the system update 29 | counter on the player's client. \|- \|} 30 | 31 | ===Client -\> Server Packets=== 32 | 33 | { 34 | --- 35 | 36 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 63 \| FIXED 37 | \| 6 \| \[\[508 Dialogue Options\|Dialogue Options.\]\] \| Sent when a 38 | player clicks an dialogue button. The data sent is InterfaceId, 39 | buttonId, and something yet not discovered. \|- \|} 40 | -------------------------------------------------------------------------------- /src/742-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RS2\]\] 2 | 3 | ===Server -\> Client Packets=== {\| border=2 \|- ! Opcode ! Type ! Size 4 | ! Name ! Description \|- \| 47 \| Unknown \| 23 \| \[\[742 Interface 5 | Packet\|Interface Packet\]\] \| Produces an interface for the player to 6 | see. \|- \| 116 \| Unknown \| -1 \| \[\[742 Commands Packet\|Commands 7 | Packet\]\] \| The packet to utilize commands. \|- \| 156 \| Unknown \| 8 | -3 \| \[\[742 A Config Packet\|A Config Packet\]\] \| A packet to send 9 | one of the four/five types of configs. \|- \| 89 \| Unknown \| -2 \| 10 | \[\[742 Maps Packet\|Maps Packet\]\] \| A packet that sends the loading 11 | of maps. \|- \| 90 \| Unknown \| -2 \| \[\[742 Player Update 12 | Packet\|Player Update Packet\]\] \| A packet to update the player's 13 | appearance etcetera. \|- \| 72 \| Unknown \| -2 \| \[\[742 NPC Update 14 | Packet\|NPC Update Packet\]\] \| A packet to update a NPC's appearance 15 | etcetera. \|- \| 29 \| Unkown \| -2 \| \[\[742 RunScripts 16 | Packet\|RunScripts Packet\]\] \| A packet to send Runscripts. \|- \| 67 17 | \| Unkown \| -2 \| \[\[742 Items Packet\|Items Packet\]\] \| A packet to 18 | load items in a way? \|- \| 120 \| Unkown \| -1 \| \[\[742 Friends Chat 19 | Receive Message Packet\|Friends Chat Receive Message Packet\]\] \| A 20 | packet that sends the FC message. \|- \| 147 \| Unkown \| 2 \| \[\[742 21 | System Update Packet\|System Update Packet\]\] \| A packet for the 22 | system update timer. \|- \| 6 \| Unkown \| 3 \| \[\[742 World Tile 23 | Packet\|World Tile Packet\]\] \| A packet to send the World Tile. \|- \| 24 | 29 \| Unkown \| -2 \| \[\[742 RunScripts Packet\|RunScripts Packet\]\] 25 | \| A packet to send Runscripts. \|- \| 40 \| Unkown \| 1 \| \[\[742 Send 26 | Skills Packet\|Send Skills Packet\]\] \| A packet to send the skills of 27 | a player. \|- \|} 28 | -------------------------------------------------------------------------------- /src/377/377-Open-Welcome-Screen.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] {{packet\|name=Open 2 | Welcome Screen\|description=Displays the welcome 3 | screen.\|opcode=21\|type=Fixed\|length=23\|revision=377}} == Open 4 | Welcome Screen == 5 | 6 | === Description === Displays the welcome screen. 7 | 8 | === Packet Structure === 9 | 10 | {\| border=2 ! Data type ! Description \|- \| \[\[Data Types\#Big 11 | Endian\|Big Endian\]\] \[\[Data Types\#Standard data types\|Short\]\] \| 12 | Last password change occurance \|- \| \[\[Data Types\#Big Endian\|Big 13 | Endian\]\] \[\[Data Types\#Standard data types\|Short\]\] \[\[Data 14 | Types\#Non Standard Data Types\|Special A\]\] \| Unknown \#1. \|- \| 15 | \[\[Data Types\#Standard data types\|Short\]\] \| Unused \#1. \|- \| 16 | \[\[Data Types\#Standard data types\|Short\]\] \| Unknown \#2. \|- \| 17 | \[\[Data Types\#Big Endian\|Big Endian\]\] \[\[Data Types\#Standard data 18 | types\|Short\]\] \| Current server time. \|- \| \[\[Data Types\#Standard 19 | data types\|Short\]\] \[\[Data Types\#Non Standard Data Types\|Special 20 | A\]\] \| Inbox message count. \|- \| \[\[Data Types\#Standard data 21 | types\|Short\]\] \[\[Data Types\#Non Standard Data Types\|Special A\]\] 22 | \| Last log-in time. \|- \| \[\[Data Types\#Standard data 23 | types\|Short\]\] \| Amount of members credit (days) remaining. \|- \| 24 | \[\[Data Types\#Big Endian\|Big Endian\]\] \[\[Data Types\#Standard data 25 | types\|Int\]\] \| Last log-in IPV4 address. \|- \| \[\[Data Types\#Big 26 | Endian\|Big Endian\]\] \[\[Data Types\#Standard data types\|Short\]\] 27 | \[\[Data Types\#Non Standard Data Types\|Special A\]\] \| Recovery 28 | question change status. \|- \| \[\[Data Types\#Standard data 29 | types\|Byte\]\] \[\[Data Types\#Non Standard Data Types\|Special A\]\] 30 | \| Unused \#2. \|- \|} \* May be inaccurate. 31 | -------------------------------------------------------------------------------- /src/JAGGRAB-Protocol.md: -------------------------------------------------------------------------------- 1 | # JAGGGRAB protocol 2 | 3 | # Introduction 4 | 5 | In the early days of the client, it was distributed as an embedded 6 | JAR within a web page. 7 | So, reloading the web page would result in the user being served an up-to-date 8 | client. 9 | However, the cache files were stored locally and thus required a separate 10 | mechanism for updating. 11 | 12 | The JAGGRAB protocol addresses this by updating the client's cache files. 13 | It does this by 'grabbing' cache files from the file server and downloading them. 14 | 15 | It is a text-based protocol, similar to HTTP/0.9, and the client will 16 | fall-back to HTTP if JAGGRAB is unavailable. This generally happens in 17 | unsigned mode and helps users who are behind firewalls. 18 | 19 | ## Request format 20 | 21 | A request is simply the text JAGGRAB, a space, the path to the file and 22 | a newline character. Therefore, it is very similar to a HTTP/0.9 GET 23 | request. 24 | 25 | e.g. `JAGGRAB /path/to/file`. 26 | 27 | Note: In possibly all new engine clients, the client prefixes the JAGGRAB 28 | request line with a single byte (value 17). 29 | 30 | ## Response format 31 | 32 | The response is the file bytes. Once the response is sent, the connection 33 | is closed. 34 | 35 | ## Files 36 | 37 | There are a number of files which map to files in the cache. 38 | 39 | - `/crc` - the CRC table 40 | - `/title` - cache 0, file 1 41 | - `/config` - cache 0, file 2 42 | - `/interface` - cache 0, file 3 43 | - `/media` - cache 0, file 4 44 | - `/versionlist` - cache 0, file 5 45 | - `/textures` - cache 0, file 6 46 | - `/wordenc` - cache 0, file 7 47 | - `/sounds` - cache 0, file 8 48 | 49 | Note: the client will usually postfixes these with random numbers, so when 50 | checking for the file only the start of the string should be examined: 51 | not the whole one. 52 | This is to help avoid caches when these files are fetched over HTTP. 53 | 54 | Note: The crc is postfixed with the client revision. 55 | -------------------------------------------------------------------------------- /src/RuneScape-Protocol.md: -------------------------------------------------------------------------------- 1 | # RuneScape Protocol 2 | 3 | The RuneScape Protocol is the protocol used for data transmission 4 | between the RuneScape client and server. 5 | The protocol changes with every revision, however, typically only the packet 6 | opcodes are changed, and possibly some new packets are added. 7 | 8 | The entire protocol is generally separated into two sub-protocols: 9 | 10 | * Login Protocol 11 | * Game Protocol 12 | 13 | ## Login Protocol 14 | 15 | The Login Protocol is the protocol that is used to log a player into 16 | RuneScape. This protocol contains information that sets up the 17 | encryption for the entire session, using the ISAAC algorithm. The "login 18 | block" is encrypted using RSA to prevent third party programs from 19 | packet-sniffing the ISAAC cipher keys and breaking the session 20 | encryption for the purpose of monitoring, injecting, and generally 21 | sniffing packets. 22 | 23 | ## Game Protocol 24 | 25 | The Game Protocol is the protocol in which game action information is 26 | transmitted. The opcodes are encrypted using ISAAC in order to prevent 27 | third party programs from tampering with the stream. The game protocol 28 | is made up of packets that are structured like so: 29 | 30 | ``` 31 | for fixed-size packets: 32 | opcode, payload[size] 33 | 34 | for variable-sized packets: 35 | opcode, size, payload[size] 36 | ``` 37 | 38 | The `opcode` of a game packet is basically an identifier for the type 39 | of game action that the packet represents. The `size` of the packet is 40 | the amount of bytes that the payload of the packet carries, and the 41 | `payload` is an array of bytes that holds the actual data 42 | (information) of the packet. 43 | 44 | A `fixed-size` packet is a packet whose payload size does never 45 | change, and the size for the specified opcode is already known between 46 | both client and server. A `variable-sized` packet is a packet whose 47 | payload size changes according to the situation of the game session. 48 | -------------------------------------------------------------------------------- /src/Privacy-policy.md: -------------------------------------------------------------------------------- 1 | 2 |
3 | What information do we collect?

We collect 4 | information from you when you register on our site or information posted 5 | on our site.

When ordering or registering on our site, as 6 | appropriate, you may be asked to enter your: e-mail address. You may, 7 | however, visit our site anonymously.

What do we use 8 | your information for?

Any of the information we 9 | collect from you may be used to improve customer service (your 10 | information helps us to more effectively respond to your customer 11 | service requests and support needs)

How do we protect 12 | your information?

We implement a variety of 13 | security measures to maintain the safety of your personal information 14 | when you enter, submit, or access your personal information. 15 |

Do we use cookies?

Yes (Cookies 16 | are small files that a site or its service provider transfers to your 17 | computers hard drive through your Web browser (if you allow) that 18 | enables the sites or service providers systems to recognize your browser 19 | and capture and remember certain information

We use cookies 20 | to compile aggregate data about site traffic and site interaction so 21 | that we can offer better site experiences and tools in the 22 | future.

Do we disclose any information to outside 23 | parties?

We do not sell, trade, or otherwise 24 | transfer to outside parties your personally identifiable information. 25 | This does not include trusted third parties who assist us in operating 26 | our website, conducting our business, or servicing you, so long as those 27 | parties agree to keep this information confidential. We may also release 28 | your information when we believe release is appropriate to comply with 29 | the law, enforce our site policies, or protect ours or others rights, 30 | property, or safety. However, non-personally identifiable visitor 31 | information may be provided to other parties for marketing, advertising, 32 | or other uses.

33 | -------------------------------------------------------------------------------- /src/317/317-Camera-shake.md: -------------------------------------------------------------------------------- 1 | # Camera oscillate 2 | Begins camera oscillation, which is implemented using a configurable sinusoidal oscillator to offset a specific degree of freedom. 3 | 4 | ## Packet Details 5 | | Key | Value | 6 | |--|--| 7 | | Name | Camera oscillate | 8 | | Description | Begin camera oscillation. | 9 | | Opcode | 35 | 10 | | Type | Fixed | 11 | | Length | 4 | 12 | | Revision | 317 | 13 | 14 | ## Packet Structure 15 | | Data Type | Description | 16 | |--|--| 17 | | [Byte](/Data-Types.html#common-data-types) | Parameter (camera X, Z, Y, yaw, pitch) | 18 | | [Byte](/Data-Types.html#common-data-types) | Jitter (for randomization) | 19 | | [Byte](/Data-Types.html#common-data-types) | Amplitude | 20 | | [Byte](/Data-Types.html#common-data-types) | Frequency (scaled by 100) | 21 | 22 | ## Other Information 23 | The oscillate event enables the client to oscillate one of 5 of it's position parameters. 24 | i.e. corresponding to the camera's degrees of freedom; parameters 0, 1, and 2 refer to the location of the camera, while 3 and 4 deal with the camera's orientation. 25 | Together, these enable complex effects involving manipulation of the camera position to give rise to simulated earth-quakes and camera shock. 26 | 27 | | Parameter | Description | 28 | |--|--| 29 | | 0 | Camera location along world X axis (a horizontal axis, aligned with map grid X) | 30 | | 1 | Camera location along world Z axis (vertical axis) | 31 | | 2 | Camera location along world Y axis (a horizontal axis, aligned with map grid Y) | 32 | | 3 | Camera orientation in world X plane w.r.t. world Z axis, i.e. yaw | 33 | | 4 | Camera orientation in world Z plane w.r.t. world X axis, i.e. pitch | 34 | 35 | Note there is no built-in way to manipulate camera roll, as this is not one of the camera's degrees of freedom. 36 | 37 | ## What it's doing 38 | Every time the world is rendered, each camera parameter that is enabled for oscillation is offset by a value computed as follows: 39 | 40 | | Calculation | Formula | 41 | |--|--| 42 | | Delta | `(int) ((Math.random() * (double) (jitter * 2 + 1) - (double) jitter) + Math.sin((double) phase * ((double) frequency / 100D)) * (double) amplitude);` | 43 | 44 | Each parameter's phase accumulator (phase) is incremented by 1 each logic update. 45 | 46 | ## Parameter 47 | The offset itself is detailed as follows for each parameter: 48 | 49 | | Parameter | Action | 50 | |--|--| 51 | | 0 | `camera_x += delta` | 52 | | 1 | `camera_z += delta` | 53 | | 2 | `camera_y += delta` | 54 | | 3 | `camera_yaw = camera_yaw + delta & 0x7ff;` | 55 | | 4 | `camera_pitch += delta` | 56 | 57 | Note that the camera's yaw is corrected modulo 0x7ff, or 2048, which is equivalent to 2 \pi radians in Jagex's binary angle system. 58 | This is not done to the camera pitch, which is instead clamped (see below). 59 | 60 | ## Note 61 | For oscillating the camera pitch, clamping is done to ensure the angle not out of bounds: 62 | 63 | ```java 64 | if (camera_pitch < 128) 65 | camera_pitch = 128 66 | if (camera_pitch > 383) 67 | camera_pitch = 383 68 | ``` 69 | 70 | This is due to Jagex restricting the possible range of orientations the camera may take. 71 | -------------------------------------------------------------------------------- /src/718-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 718\]\] \[\[Category RS2\]\] 2 | 3 | == '''Packet structure''' == ? 4 | 5 | == '''Login''' == ? 6 | 7 | == '''Game Protocol''' == 8 | 9 | ===Server -\> Client Packets=== 10 | 11 | { 12 | --- 13 | 14 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 2 \| 15 | VARIABLE\_SHORT \| -2 \| \[\[718 Friends packet\|Friends packet\]\] \| 16 | Sends a friend to the friend list. \|- \| 5 \| FIXED \| 4 \| \[\[718 17 | Close window\|Close window\]\] \| Closes an interface. \|- \| 6 \| FIXED 18 | \| 1 \| \[\[718 Player under NPC priority\|Player under NPC priority\]\] 19 | \| N/A \|- \| 9 \| FIXED \| 6 \| \[\[718 Music effect\|Music effect\]\] 20 | \| Plays a music effect. \|- \| 10 \| VARIABLE\_BYTE \| -1 \| \[\[718 21 | Set mouse\|Set mouse\]\] \| N/A \|- \| 11 \| FIXED \| -2 \| \[\[718 22 | World list\|World list\]\] \| Sends the world list. \|- \| 14 \| FIXED 23 | \| 23 \| \[\[718 Interface\|Interface\]\] \| Opens an interface. \|- \| 24 | 17 \| VARIABLE\_SHORT \| -2 \| \[\[718 Open URL\|Open URL\]\] \| Opens a 25 | hyperlink. \|- \| 20 \| FIXED \| 16 \| \[\[718 26 | Projectile\|Projectile\]\] \| Plays a projectile. \|- \| 23 \| FIXED \| 27 | 4 \| \[\[718 Player on IComponent\|Music effect\]\] \| N/A \|- \| 25 \| 28 | FIXED \| 1 \| \[\[718 Run energy\|Run energy\]\] \| Sends the run 29 | energy. \|- \| 30 \| VARIABLE\_BYTE \| -1 \| \[\[718 Send friend quick 30 | chat\|Send friend quick chat\]\] \| Sends a friend a quick chat message. 31 | \|- \| 31 \| FIXED \| 8 \| \[\[718 Model on IComponent\|Model on 32 | IComponent\]\] \| Sends a model to an IComponent (child interface). \|- 33 | \| 32 \| FIXED \| -1 \| \[\[718 Receive friend quick chat\|Receive 34 | friend quick chat\]\] \| Displays a received quick chat message to a 35 | friend. \|- \| 33 \| VARIABLE\_BYTE \| -1 \| \[\[718 Receive personal 36 | message\|Receive personal message\]\] \| Received a private message (PM) 37 | and displays it. \|- \| 39 \| FIXED \| 19 \| \[\[718 Game pane\|Game 38 | pane\]\] \| Sends the game pane. \|- \| 40 \| FIXED \| 12 \| \[\[718 39 | IComponent Settings\|IComponent Settings\]\] \| N/A \|- \| 42 \| 40 | VARIABLE\_SHORT \| -2 \| \[\[718 Load map scene\|Load map scene\]\] \| 41 | Loads a map. \|- \| 44 \| FIXED \| 6 \| \[\[718 Shake camera\|Shake 42 | camera\]\] \| Shakes the camera of the character. \|- \| 45 \| FIXED \| 43 | 2 \| \[\[718 Destroy object\|Destroy object\]\] \| Removes an object 44 | from the screen. \|- \| 55 \| VARIABLE\_SHORT \| -2 \| \[\[718 45 | Ignores\|Ignores\]\] \| Sends a player to a player's ignore list. \|- 46 | \|} 47 | 48 | ===Client -\> Server Packets=== 49 | 50 | { 51 | --- 52 | 53 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 3 \| FIXED 54 | \| 16 \| \[\[718 Item on item\|Item on item\]\] \| Send an item on item 55 | request. \|- \| 4 \| VARIABLE\_BYTE \| -1 \| \[\[718 Add ignore\|Add 56 | ignore\]\] \| Sends a request to add a person to a person's ignore list. 57 | \|- \| 8 \| VARIABLE\_BYTE \| -1 \| \[\[718 Walk\|Walk\]\] \| Sends a 58 | request to walk to specific coordinates. \|- \| 9 \| FIXED \| 3 \| 59 | \[\[718 NPC Examine\|NPC Examine\]\] \| Sends a request to examine an 60 | NPC. \|- \|} 61 | -------------------------------------------------------------------------------- /src/474-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 474\]\] \[\[Category RS2\]\] 2 | 3 | Not much progress has been made with this revision, don't worry about it 4 | too much. 5 | 6 | == '''Packet structure''' == When the client sends a packet to the 7 | server, the first byte encapsulates its opcode. This specific opcode is 8 | encrypted with a value generated by the ISAAC PRNG seeded with a 9 | dynamically server generated key during the login block. The server 10 | decrypts it and associates the opcode to the packet's respective 11 | predefined size. If the packet does not contain a fixed size, the opcode 12 | will be followed by either a byte or a word - varying per packet - for 13 | its proper size. This is then followed by the payload. 14 | 15 | == '''Login''' == ? 16 | 17 | == '''Game Protocol''' == 18 | 19 | ===Server -\> Client Packets=== 20 | 21 | { 22 | --- 23 | 24 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 209 \| 25 | VARIABLE\_BYTE \| N/A \| \[\[474 Send message\|Send message\]\] \| Sends 26 | a server message (e.g. 'Welcome to RuneScape') or trade/duel request. 27 | \|- \| 231 \| VARIABLE\_SHORT \| N/A \| \[\[474 Send string\|Send 28 | string\]\] \| Replaces a string of text. (e.g. Replace: 'Click here to 29 | Play' with 'Play Now!') \|- \|} 30 | 31 | ===Client -\> Server Packets=== 32 | 33 | { 34 | --- 35 | 36 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 1 \| FIXED 37 | \| 8 \| \[\[474 Remove ignore\|Remove ignore\]\] \| Sent when a player 38 | removes a player from their ignore list. \|- \| 3 \| FIXED \| 6 \| 39 | \[\[474 Fourth Interface Option\|Fourth Interface Option\]\] \| This is 40 | triggered when a fourth interface option has been clicked. \|- \| 4 \| 41 | FIXED \| N/A \| \[\[474 Fourth Object Option\|Fourth Object Option\]\] 42 | \| This is triggered when a fourth object option has been clicked. \|- 43 | \| 11 \| FIXED \| N/A \| \[\[474 Minimap Walk\|Minimap Walk\]\] \| Sends 44 | walking data to the server. \|- \| 13 \| FIXED \| 12 \| \[\[474 Item on 45 | NPC\|Item on NPC\]\] \| Sent when a player uses an item on an NPC. \|- 46 | \| 21 \| FIXED \| 2 \| \[\[474 Npc action 2\|Npc action 2\]\] \| Sent 47 | when a player clicks the second option of an NPC. \|- \| 22 \| FIXED \| 48 | N/A \| \[\[474 Kick Clanchat Participant\|Kick Clanchat Participant\]\] 49 | \| Indicates a friend of the clanChat owner attempts to kick a fellow 50 | clanChatParticipant (non-owner). \|- \| 29 \| FIXED \| N/A \| \[\[474 51 | Sixth Interface Option\|Sixth Interface Option\]\] \| Tells the server a 52 | sixth interface option has been clicked. \|- \| 31 \| FIXED \| 6 \| 53 | \[\[474 Object action 1\|Object action 1\]\] \| Sent when the player 54 | clicks the first option of an object, such as "Cut" for trees. \|- \| 34 55 | \| FIXED \| N/A \| \[\[474 Client Focus\|Client Focus\]\] \| Tells the 56 | server the clients focus has changed. \|- \| 35 \| FIXED \| N/A \| 57 | \[\[474 Use Magic On Player\|Use Magic On Player\]\] \| Indicates the 58 | player wants to use a spell on another player. \|- \| 37 \| FIXED \| N/A 59 | \| \[\[474 Third interface option\|Third interface option\]\] \| This is 60 | triggered when one a third interface option has been clicked. \|- \| 203 61 | \| FIXED \| 6 \| \[\[474 Object action 2\|Object action 2\]\] \| Sent 62 | when the player clicks the second option of an object, such as 63 | "Use-quickly" for Bank Booths. \|- \| 34 \| FIXED \| 1 \| \[\[474 Focus 64 | change\|Focus change\]\] \| Sent when the game client window goes out of 65 | focus. \|- \| 35 \| FIXED \| 8 \| \[\[474 Magic on player\|Magic on 66 | player\]\] \| Sent when the player casts magic on another player.\ 67 | \|- \| 226 \| FIXED \| 2 \| \[\[474 Examine object\|Examine object\]\] 68 | \| Sent when you examine an object.\ 69 | \|- \|} 70 | -------------------------------------------------------------------------------- /src/377/377-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category Packet\]\] \[\[Category Packet 377\]\] \[\[Category RS2\]\] 2 | 3 | == '''Login Protocol''' == 4 | 5 | The Login protocol is identical to the \[\[317 Protocol\#Login Protocol 6 | Overview\|317 Login protocol\]\]. 7 | 8 | ==Game Protocol== The game protocol is the in-game communication of 9 | player actions between the server and client.
10 | 11 | ===Server -\> Client Packets=== 12 | 13 | { 14 | --- 15 | 16 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- ! 2 ! FIXED ! 17 | 4 ! \[\[377 Interface Animation\|Interface Animation\]\] ! Sets an 18 | interface's model animation. \|- ! 3 ! FIXED ! 6 ! \[\[377 Move 19 | Camera\|Camera Move\]\] ! Moves the camera. \|- ! 5 ! FIXED ! 0 ! 20 | \[\[377 Logout\|Logout\]\] ! Disconnects the client from the server. \|- 21 | ! 10 ! FIXED ! 3 ! \[\[377 Send Sidebar Interface\|Send Sidebar 22 | Interface\]\] ! Assigns an interface to one of the tabs in the game 23 | sidebar. \|- ! 13 ! FIXED ! 0 ! \[\[377 Animation Reset\|Animation 24 | Reset\]\] ! Resets all entity animations in the immediate area. \|- ! 18 25 | ! FIXED ! 6 ! \[\[377 Interface Model Rotation\|Interface Model 26 | Rotation\]\] ! Sets the rotation speed of an item in an interface. \|- ! 27 | 21 ! FIXED ! 6 ! \[\[377 Interface Item\|Interface Item\]\] ! Displays 28 | an item model inside an interface. \|- ! 26 ! FIXED ! 5 ! \[\[377 Send 29 | Sound\|Send Sound\]\] ! Sends a sound to be played. \|- ! 29 ! FIXED ! 0 30 | ! \[\[377 Reset Open Interfaces\|Reset Open Interfaces\]\] ! Resets all 31 | opened interfaces. \|- ! 40 ! FIXED ! 2 ! \[\[377 Reset Ground Items and 32 | Objects\|Reset Ground Items and Objects\]\] ! Resets all ground items 33 | and objects in a 8x8 region. \|- \|- ! 41 ! FIXED ! 4 ! \[\[377 Play 34 | Ambient Wave\|Play Ambient Wave\]\] ! Plays an ambient wave. \|- ! 49 ! 35 | FIXED ! 6 ! \[\[377 Skill Level\|Skill Level\]\] ! Sends a skill level 36 | to the client. \|- ! 50 ! FIXED ! 2 ! \[\[377 Walkable 37 | Interface\|Walkable Interface\]\] ! Displays an interface in walkable 38 | mode. \|- ! 53 ! VARIABLE\_SHORT ! N/A ! \[\[377 Construct Map 39 | Region\|Construct Map Region\]\] ! Constructs a map region given the 40 | region's x and y coordinate. \|- ! 58 ! FIXED ! 0 ! \[\[377 Input 41 | Amount\|Input Amount\]\] ! Displays the "Input amount" interface. \|- ! 42 | 59 ! FIXED ! 6 ! \[\[377 Create Static Graphic\|Create Static 43 | Graphic\]\] ! Creates a static graphic. \|- ! 61 ! FIXED ! 0 ! \[\[377 44 | Clear Waypoint\|Clear Waypoint\]\] ! Resets the waypoint. \|- ! 63 ! 45 | VARIABLE\_BYTE ! N/A ! \[\[377 Send Message\|Send Message\]\] ! Sends a 46 | server message (e.g. 'Welcome to RuneScape') or trade/duel request. \|- 47 | ! 67 ! FIXED ! 4 ! \[\[377 Camera Shake\|Camera Shake\]\] ! Causes the 48 | camera to shake. \|- ! 71 ! VARIABLE\_SHORT ! N/A ! \[\[377 Update 49 | Npcs\|Update Npcs\]\] ! Updates NPCs. \|- ! 75 ! FIXED ! 2 ! \[\[377 50 | Send Position\|Send Position\]\] ! Sends a position (used for packets 51 | such as Ground Items and Projectiles) \|- ! 76 ! FIXED ! 23 ! \[\[377 52 | Open Welcome Screen\|Open Welcome Screen\]\] ! Displays the welcome 53 | screen. \|- ! 78 ! FIXED ! 9 ! \[\[377 Send Add Friend\|Send Add 54 | Friend\]\] ! Sends a friend to be added to the friend list. \|- ! 82 ! 55 | FIXED ! 3 ! \[\[377 Set Widget Mouse Triggered\|Set Widget Mouse 56 | Triggered\]\] ! Set widget mouse triggered. \|- ! 88 ! FIXED ! 2 ! 57 | \[\[377 Create Object\|Create Object\]\] ! Sends a friend to be added to 58 | the friend list. \|- ! 90 ! VARIABLE\_SHORT ! N/A ! \[\[377 Update 59 | Players\|Update Players\]\] ! Updates players. \|- ! 107 ! FIXED ! 5 ! 60 | \[\[377 Send Ground Item\|Send Ground Item\]\] ! Adds a ground item to 61 | the server. \|- ! 113 ! FIXED ! 0 ! \[\[377 Reset Button State\|Reset 62 | Button State\]\] ! Resets the button state for all buttons. \|- ! 125 ! 63 | FIXED ! 1 ! \[\[377 Run Energy\|Run Energy\]\] ! Sends the players run 64 | energy level. \|- ! 126 ! FIXED ! 3 ! \[\[377 Initialize 65 | Player\|Initialize Player\]\] ! Sends the player's membership status and 66 | their current index on the server's player list. \|- ! 128 ! FIXED ! 4 ! 67 | \[\[377 Inventory Overlay\|Inventory Overlay\]\] ! Displays an interface 68 | over the sidebar area. \|-} 69 | -------------------------------------------------------------------------------- /src/Data-Types.md: -------------------------------------------------------------------------------- 1 | # Data types 2 | 3 | RuneScape uses a number of common and bespoke data types in the 4 | process of data transmission. 5 | 6 | ## Byte Order 7 | 8 | Data types that are two bytes or larger can be stored and ordered in a 9 | variety of different ways. 10 | The traditional byte orders are big endian and little endian. 11 | Generally people either use big endian or little endian. 12 | 13 | RuneScape uses both little and big-endian byte orders throughout the 14 | protocol (however, the 194 client only uses big-endian order). 15 | This presumably to make reverse-engineering of the protocol harder. 16 | 17 | Note: Some confusion has arisen over the byte order as the data types 18 | are named incorrectly in Winterlove's server where little endian data 19 | types are incorrectly named as big endian types. 20 | 21 | ### Big Endian 22 | 23 | In big endian order, the most significant byte (MSB) is stored first and 24 | the least significant byte (LSB) is stored last. 25 | 26 | ### Little Endian 27 | 28 | In little endian order, the least significant byte (LSB) is stored first 29 | and the most significant byte (MSB) is stored last. 30 | 31 | ## Bespoke Byte Orders 32 | 33 | Additionally, RuneScape also uses two endian orders for integers that 34 | are different from a big- or low endian order. 35 | We call these byte orders middle endian. 36 | 37 | ### Middle Endian Big Int 38 | 39 | The bytes are stored in the following order, where A1 is the smallest byte (I.e. LSB) and D4 the bigger (i.e. MSB): C3 D4 A1 B2. 40 | 41 | ### Middle Endian Small Int 42 | 43 | The bytes are stored in the following order, where A1 is the smallest byte (I.e. LSB) and D4 the bigger (i.e. MSB): B2 A1 D4 C3. 44 | 45 | ## Common data types 46 | 47 | These data types are traditional, hence they can typically be written 48 | and read by a standard DataStream, or Buffer implementation. 49 | 50 | Naming conventions: 51 | 52 | | Standardized name | Data-type name | Jagex name | Encoding | 53 | |---|---|---|---| 54 | | Byte | byte | 1,1b | Bytes | 55 | | [Word](./Word.md) | short | 2,2b | Bytes | 56 | | [DWord](./DWord.md) | int, int32 | 2,2b | Bytes | 57 | | [QWord](./QWord.md) | long, int64 | 8,8b | Bytes | 58 | | C-style String | string, String, char*, char[] | str, strbyte | Text bytes followed by `\n` or the byte `10`. | 59 | | Java-string String | string, String, char*, char[] | strraw | Length as a word, followed by the text bytes. | 60 | 61 | Note: In more recent versions of the client, C-style strings are terminated with the null character (i.e. `\0`) or the byte `0` to support multi-line strings. 62 | 63 | ## Bespoke data types 64 | 65 | These data types are bespoke, that is, they were developed with the 66 | sole intention of only being used within Jagex products. 67 | 68 | We presume that this is another technique employed to make 69 | reverse-engineering and packet manipulation harder. 70 | 71 | Naming conventions: 72 | 73 | | Winterlove's name | Jagex name | Read transformation | Write transformation | 74 | |---|---|---|---| 75 | | Special A | Unknown | value - 128 | value + 128 | 76 | | Special C | Unknown | 0 - value | 0 - value | 77 | | Special S | Unknown | 128 - value | 128 - value | 78 | | SpaceSaverA | smarts | `(value[0] < 128) ? (((value[0] - 128) << 8) + value[1]) : value[0]` | `if(value < 128) putword(value+32768) else putbyte(value);` | 79 | | SpaceSaverB | smart | `(value[0] << 24) + (value[1] << 16) + value[2] ` | `putbyte(value >> 24); putbyte(value >> 16); putbyte(value); ` | 80 | | Tribyte, RGBColour, 3Byte, int3, medium | 3 | `(value[0] << 24) + (value[1] << 16) + value[2]` | `putbyte(value >> 24); putbyte(value >> 16); putbyte(value); ` | 81 | | [RS String](./RS-String.md) | jstr | Old engine: read until newline terminated ("\n"). New engine: read until null byte (value 0). | Old engine: write and finish with newline delimiter ("\n"). New engine: write and finish with null byte (value 0). | 82 | 83 | Note: The read transformation is the process which must be applied to 84 | read data, to reconstruct the original. 85 | The write transformation applies analogously, to when data is written. 86 | 87 | ## Bit Access 88 | 89 | ### Initiating Bit Access 90 | 91 | Whenever data is to be sent to the server or to the client using bits; 92 | the stream needs to be prepared by setting the bit position. 93 | The bit position can be calculated by multiplying the current buffer 94 | position by 8. This is because each byte is comprised of 8 bits. 95 | 96 | e.g. `int bitPos = bufferPos * 8;` 97 | -------------------------------------------------------------------------------- /src/Class-Check.md: -------------------------------------------------------------------------------- 1 | # Class check 2 | 3 | The class check originated with the new Runescape engine update which 4 | took place around the 4xx revisions. 5 | It gives the Jagex servers the ability to check the modifiers, update, 6 | or fetch the value for a field. 7 | It also gives functionality to invoke a method with parameters and get 8 | it's return value, or check it's modifiers. 9 | Each of these functionalities are described with a request type. 10 | A class check request is built up with many of these request types. 11 | Each request is tagged with an unique id. 12 | 13 | ## Request format 14 | 15 | ``` 16 | unsigned byte numberOfRequests; 17 | int uid; 18 | byte[] requests_block; 19 | ``` 20 | 21 | The `requests_block` is comprised of multiple requests, each with the following format: 22 | 23 | ``` 24 | unsigned byte type; 25 | type-dependent data; 26 | ``` 27 | 28 | ## Response format 29 | 30 | ``` 31 | int uid; 32 | byte[] responses_block; 33 | short payloadCrc; 34 | ``` 35 | 36 | The `responses_block` is comprised of multiple responses, each with the following format: 37 | 38 | ``` 39 | byte responseCode; 40 | type-dependent data; 41 | ``` 42 | 43 | ## Request Types 44 | 45 | For request types 0, 2, 4 there will only be one successful response 46 | code and a short value of the value being requested will be sent. 47 | For request type 1, only the successful response code will be used but no 48 | value will be sent back. 49 | 50 | | Opcode | Name | Description | 51 | |---|---|---| 52 | | 0 | Fetch fumeric field | Fetches the value of a numeric field. | 53 | | 1 | Update numeric field | Updates the value of a numeric field. | 54 | | 2 | Get field modifiers | Gets the modifiers of a field. | 55 | | 3 | Invoke method | Invokes a method and sends back its return object. | 56 | | 4 | Get method modifiers | Gets the modifiers of a method. | 57 | 58 | ## Return Codes 59 | 60 | For opcode 0, there are cases where a numeric value is sent to the server 61 | on fetch requests. 62 | This value is always a short. 63 | 64 | For a method invoke request, there isn't a value that is sent to the server. 65 | It is just assumed that there wasn't a return object from the invoked method. 66 | 67 | | Opcode | Name | On Receive/Response | Description | 68 | |---|---|---|---| 69 | | 0 | Successful | Response | Successfully executed the request. | 70 | | 1 | Successful - Returned numeric value | Response | Successfully executed the request, and returned a numeric value. | 71 | | 2 | Successful - Returned string value | Response | Successfully executed the request, and returned a string value. | 72 | | 4 | Successful - Returned object value | Response | Successfully executed the request, and returned an object value. | 73 | | -1 | ClassNotFoundException | Receive | A ClassNotFoundException was thrown while receiving a request from the server. | 74 | | -2 | SecurityException | Receive | A SecurityException was thrown while receiving a request from the server. | 75 | | -3 | NullPointerException | Receive | A NullPointerException was thrown while receiving a request from the server. | 76 | | -4 | Exception | Receive | An Exception was thrown while receiving a request from the server. | 77 | | -5 | Throwable | Receive | An error or exception was thrown while receiving a request from the server. | 78 | | -10 | ClassNotFoundException | Response | A ClassNotFoundException was thrown while responding to a request from the server. | 79 | | -11 | InvalidClassException | Response | An InvalidClassException was thrown while responding to a request from the server. | 80 | | -12 | StreamCorruptedException | Response | A StreamCorruptedException was thrown while responding to a request from the server. | 81 | | -13 | OptionDataException | Response | An OptionDataException was thrown while responding to a request from the server. | 82 | | -14 | IllegalAccessException | Response | An IllegalAccessException was thrown while responding to a request from the server. | 83 | | -15 | IllegalArgumentException | Response | An IllegalArgumentException was thrown while responding to a request from the server. | 84 | | -16 | InvocationTargetException | Response | An InvocationTargetException was thrown while responding to a request from the server. | 85 | | -17 | SecurityException | Response | A SecurityException was thrown while responding to a request from the server. | 86 | | -18 | IOException | Response | An IOException was thrown while responding to a request from the server. | 87 | | -19 | NullPointerException | Response | A NullPointerException was thrown while responding to a request from the server. | 88 | | -20 | Exception | Response | An Exception was thrown while responding to a request from the server. | 89 | | -21 | Throwable | Response | An error or exception was thrown while receiving a request from the server. | 90 | -------------------------------------------------------------------------------- /src/OB3.md: -------------------------------------------------------------------------------- 1 | # 0B3 2 | 3 | This page documents the `.ob3` format, a bespoke format for 3D models 4 | created by Jagex. 5 | It is used by the RuneScape Classic engine since client version 6 | \#74. 7 | 8 | Note: There is also an earlier version of this format called `.ob2`. 9 | 10 | ## OB3 Model Class 11 | The following is the fully renamed client code used to represent OB3 models. 12 | 13 | ```java 14 | public class OB3Model { 15 | 16 | private static final int num_seq = 0xbc614e; // 12345678 17 | public int vertex_count; 18 | public int vertices_x[]; 19 | public int vertices_y[]; 20 | public int vertices_z[]; 21 | public int face_count; 22 | public int face_vertex_count[]; 23 | public int face_vertices[][]; 24 | public int face_fill_back[]; 25 | public int face_fill_front[]; 26 | public int face_gouraud[]; 27 | 28 | public OB3Model(byte data[], int offset) { 29 | int vertex_count = get_uint16(data, offset); 30 | offset += 2; 31 | int face_count = get_uint16(data, offset); 32 | offset += 2; 33 | 34 | vertices_x = new int[vertex_count]; 35 | vertices_y = new int[vertex_count]; 36 | vertices_z = new int[vertex_count]; 37 | face_vertex_count = new int[face_count]; 38 | face_vertices = new int[face_count][]; 39 | face_fill_back = new int[face_count]; 40 | face_fill_front = new int[face_count]; 41 | face_gouraud = new int[face_count]; 42 | 43 | for (int v = 0; v < vertex_count; v++) { 44 | vertices_x[v] = get_int16b(data, offset); 45 | offset += 2; 46 | } 47 | 48 | for (int v = 0; v < vertex_count; v++) { 49 | vertices_y[v] = get_int16b(data, offset); 50 | offset += 2; 51 | } 52 | 53 | for (int v = 0; v < vertex_count; v++) { 54 | vertices_z[v] = get_int16b(data, offset); 55 | offset += 2; 56 | } 57 | 58 | this.vertex_count = vertex_count; 59 | for (int f = 0; f < face_count; f++) 60 | face_vertex_count[f] = get_ubyte(data[offset++]); 61 | 62 | for (int f = 0; f < face_count; f++) { 63 | face_fill_back[f] = get_int16b(data, offset); 64 | offset += 2; 65 | if (face_fill_back[f] == 32767) 66 | face_fill_back[f] = num_seq; 67 | } 68 | 69 | for (int f = 0; f < face_count; f++) { 70 | face_fill_front[f] = get_int16b(data, offset); 71 | offset += 2; 72 | if (face_fill_front[f] == 32767) 73 | face_fill_front[f] = num_seq; 74 | } 75 | 76 | for (int f = 0; f < face_count; f++) { 77 | int i = get_ubyte(data[offset++]); 78 | if (i == 0) 79 | face_gouraud[f] = 0; 80 | else 81 | face_gouraud[f] = num_seq; 82 | } 83 | 84 | for (int f = 0; f < face_count; f++) { 85 | face_vertices[f] = new int[face_vertex_count[f]]; 86 | for (int fv = 0; fv < face_vertex_count[f]; fv++) { 87 | if (vertex_count < 256) { 88 | face_vertices[f][fv] = get_ubyte(data[offset++]); 89 | } else { 90 | face_vertices[f][fv] = get_uint16(data, offset); 91 | offset += 2; 92 | } 93 | } 94 | } 95 | 96 | this.face_count = face_count; 97 | } 98 | 99 | private static int get_ubyte(byte b) { 100 | return (b & 0xff); 101 | } 102 | 103 | private static int get_uint16(byte b[], int start) { 104 | return (get_ubyte(b[start]) << 8) + get_ubyte(b[start + 1]); 105 | } 106 | 107 | private static int get_int16b(byte b[], int start) { 108 | int i = get_ubyte(b[start]) * 256 + get_ubyte(b[start + 1]); 109 | if (i > 32767) 110 | i -= 0x10000; 111 | return i; 112 | } 113 | } 114 | ``` 115 | 116 | ## Faces 117 | 118 | A negative face_fill_back or face_fill_front value indicates a solid colour, whereas a positive value indicates a texture. 119 | The texture is defined by its offset in the client's texture array. 120 | 121 | When converting to/from [Wavefront OBJ](https://en.wikipedia.org/wiki/Wavefront_.obj_file) 122 | format, remember that the OB3 face vertices are one less than the OBJ 123 | face vertices. 124 | 125 | The below code will allow you to encode or decode colours in this format. 126 | 127 | ```java 128 | public static int decode_colour(int i) { 129 | i = -(i + 1); 130 | int r = i >> 10 & 0x1f; 131 | int g = i >> 5 & 0x1f; 132 | int b = i & 0x1f; 133 | return (r << 19) + (g << 11) + (b << 3); 134 | } 135 | 136 | public static int encode_colour(int r, int g, int b) { 137 | return -1 - (r / 8) * 1024 - (g / 8) * 32 - b / 8; 138 | } 139 | ``` 140 | -------------------------------------------------------------------------------- /src/508-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RS2\]\] 2 | 3 | == '''Packet structure''' == When the client sends a packet to the 4 | server, the first byte encapsulates its opcode. This specific opcode is 5 | encrypted with a value generated by the ISAAC PRNG seeded with a 6 | dynamically server generated key during the login block. The server 7 | decrypts it and associates the opcode to the packet's respective 8 | predefined size. If the packet does not contain a fixed size, the opcode 9 | will be followed by either a byte or a word - varying per packet - for 10 | its proper size. This is then followed by the payload. 11 | 12 | == '''Login''' == Every connection to the main 'gateway' server sends a 13 | single byte of data, mostly well known as the connection type. The 14 | connection type tells the main server which type of connection you wish 15 | to initiate. The old engine list consists of: 16 | 17 | - Login initiation - connection type 14 18 | - Update - connection type 15 19 | - Fresh login - connection type 16 20 | - JAGGRAB - connection type 17 21 | - Reconnecting login - connection type 18 22 | - Worldlist - varies, connection type 255 in \#508 23 | - Potentially more... 24 | 25 | The connection type we will cover in the following paragraphs is the 26 | login connection type, 14. After the login handshake initiating 27 | connection type, the client writes a small bit of data derived from the 28 | logging in player's username. This is believed to help select the 29 | appropriate login server. On successful handshake, the server sends back 30 | 8 ignored by 31 | 32 | At this point, the client reads in one byte, called the status code. The 33 | status code 0 is expected to start the login protocol correctly. If the 34 | status code is 0, the client reads a long, dubbed by many as the server 35 | session key. This is used to help generate a unique seed for the client 36 | session's packet opcode masking. The client then stores two ints that 37 | are the upper and lower ints of the client session key, which has the 38 | same purpose as the server's key. The client then starts writing the 39 | login block, which is RSA encrypted. 40 | 41 | The login block starts with the byte 10, which is considered a magic 42 | number. Following it is the client session key and server session key 43 | longs. Trailing behind the session keys comes the client's username 44 | packed to a 64-bit long and password written as a C-string 45 | (NUL-terminated ASCII). This block is then RSA encrypted and stored for 46 | later use. 47 | 48 | Now starts the login request packet. It starts off with a flag telling 49 | the server whether or not the client is reconnecting or connecting for 50 | the first time \[NOW CLASSIFIED AS CONNECTION TYPE\]. The byte is 18 or 51 | 16, respectively. Following is the size of the rest of the login 52 | response packet, including the login block that trails at the end, to 53 | tip the server how much data it should expect. Later comes the client 54 | revision int. After the client revision, an unknown byte is written that 55 | seems to always be zero (possibly the memory usage game-type flag \[low 56 | mem/high mem\]), followed by constantly zero byte and yet another zero 57 | byte. Next the packet writes the game applet width and height in pixels 58 | as shorts, followed quickly after by the UID (unique identifier or user 59 | identifier). Next comes the C-string settings string passed as a param 60 | to the applet, and after it the int affiliate identifier (probably 61 | identifies the game affiliate it was run on) with another int right 62 | after it. This int that trails behind is an unknown int that only has 22 63 | bits used, all of which represent various flags within the client. Any 64 | clues as to what they are would be nice. The packet is just about 65 | crafted completely. \[In 525, a strange short is written here\]. To 66 | finish off the main chunk, the client writes all cache's reference table 67 | index-based CRC32 checksums as ints (29 in 539, 27 in 508, etc). To top 68 | it off, the RSA encrypted login block is appended to the end and the 69 | packet is sent to the server. 70 | 71 | The ISAAC ciphers are seeded for packet opcode masking after adding 50 72 | to each int of the session keys, and the status code is reread. This 73 | finishes the login protocol. 74 | 75 | == '''Game Protocol''' == Game packet header: 76 | 77 |
 78 | ubyte - opcode
 79 | ubyte - packet size only if packet size is sent as -1 (length: VAR_BYTE)
 80 | ushort - packet size only if packet size is sent as -2 (length: VAR_SHORT)
 81 | 
82 | After the header is read by the server, the packet specific data is then 83 | read and decoded by the server. 84 | 85 | ===Server -\> Client Packets=== {\| border=2 \|- ! Opcode ! Type ! 86 | Length (bytes) ! Name ! Description \|- \| 8 \| FIXED \| 2 \| \[\[508 87 | System update\|System update\]\] \| Displays the system update counter 88 | on the player's client. \|- \| 93 \| FIXED \| 7 \| \[\[508 Send 89 | interface\|Send interface\]\] \| \|- \| 99 \| FIXED \| 1 \| \[\[508 Run 90 | energy\|Run energy\]\] \| Sets the players run energy. \|- \| 104 \| 91 | FIXED \| 0 \| \[\[508 Logout\|Logout\]\] \| Logs the player out. \|- \| 92 | 217 \| FIXED \| 6 \| \[\[508 Send skill levels\|Send skill levels\]\] \| 93 | Sends the player's skill levels to the client to be drawn on the skill 94 | tab. \|- \| 218 \| VARIABLE BYTE \| N/A \| \[\[508 Send message\|Send 95 | message\]\] \| Writes a string to the client's chat box. \|- \| 239 \| 96 | FIXED \| 3 \| \[\[508 Set window pane\|Set window pane\]\] \| \|- \| 252 97 | \| VARIABLE BYTE \| N/A \| \[\[508 Send player option\|Send player 98 | option\]\] \| \|} 99 | 100 | ===Client -\> Server Packets=== 101 | 102 | { 103 | --- 104 | 105 | ! Opcode ! Type ! Length (bytes) ! Name ! Description \|- \| 63 \| FIXED 106 | \| 6 \| \[\[508 Dialogue Options\|Dialogue Options.\]\] \| Sent when a 107 | player clicks an dialogue button. The data sent is InterfaceId, 108 | buttonId, and something yet not discovered. \|- \|} 109 | -------------------------------------------------------------------------------- /src/Archive-Format.md: -------------------------------------------------------------------------------- 1 | # Archive format 2 | 3 | From client revision 194 until 377, all the files in cache 0 4 | are in an archive-like format which contains a collection of named 5 | files (e.g. `BADENC.TXT` is a file which contains bad words in the 6 | `wordenc` archive). 7 | 8 | ## Usage 9 | 10 | These files are used by the client for a variety of purpose. 11 | 12 | The files themselves represent either an index, which contains 13 | information about to where to locate data in the cache, and 14 | the data themselves. 15 | 16 | e.g. `DATA` contains data for interfaces. 17 | 18 | e.g. `MAP_INDEX` contains information about where to find the map and landscape files in the cache. 19 | 20 | ## Format 21 | 22 | ``` 23 | tribyte uncompressedSize 24 | tribyte compressedSize 25 | ``` 26 | 27 | If the uncompressed and compressed sizes are equal, the whole file is 28 | not compressed but the individual entries are compressed using bzip2. 29 | If they are not equal, the entire file is compressed using bzip2 but 30 | the individual entries are not. 31 | 32 | Note: The magic id at the start of the bzip2 entries are not included 33 | in the cache. 34 | If you use an existing API to read the files and want to add this back, 35 | you must append the characters `BZh1` before you decompress. 36 | 37 | ```short fileCount``` 38 | 39 | Each file entry has the format: 40 | 41 | ``` 42 | int nameHash 43 | tribyte uncompressedSize 44 | tribyte compressedSize 45 | ``` 46 | 47 | # Extracting the data 48 | 49 | If you iterate over the files using a for-loop, you need to keep track of the 50 | file offset. 51 | The following pseudo-code demonstates how: 52 | 53 | ```java 54 | int offset = buffer.getCurrentOffset() + numFiles * 10; 55 | 56 | for(int i = 0; i < numFiles; i++) { 57 | // read values 58 | int thisFileOffset = offset; 59 | offset += thisFileCompressedSize; 60 | } 61 | ``` 62 | 63 | To acquire a named file using its name, hash the name as follows: 64 | 65 | ```java 66 | public static int hash(String name) { 67 | int hash = 0; 68 | name = name.toUpperCase(); 69 | 70 | for(int j = 0; j < name.length(); j++) { 71 | hash = (hash * 61 + name.charAt(j)) - 32; 72 | } 73 | return hash; 74 | } 75 | ``` 76 | 77 | Then, loop through the file entries you loaded earlier to find a 78 | matching hash. Read the compressed file size from the offset. If the 79 | whole file is not compressed, you should decompress the individual 80 | entry. 81 | 82 | ## \#194 Archive Format 83 | 84 | The \#194 (RuneScape 2 beta) client worked with a very simple cache 85 | format. 86 | Each file in the cache corresponded to a file on the operating system. 87 | 88 | ### Name hashing 89 | 90 | Every name in the cache was hashed using the following method which is, 91 | incidentally, similar to the way player names are converted to longs. 92 | 93 | ```java 94 | public static final long gethash(String string) { 95 | string = string.trim(); 96 | long l = 0L; 97 | 98 | for (int i = 0; i < string.length() && i < 12; i++) { 99 | char c = string.charAt(i); 100 | l \*= 37L; 101 | 102 | if (c >= 'A' && c <= 'Z') 103 | l += (long) ('\\001' + c - 'A'); 104 | else if (c >= 'a' && c <= 'z') 105 | l += (long) ('\\001' + c - 'a'); 106 | else if (c >= '0' && c <= '9') 107 | l += (long) ('\\033' + c - '0'); 108 | } 109 | return l; 110 | } 111 | ``` 112 | 113 | The resulting long was converted to a string and the file was given that 114 | name. 115 | 116 | ### Files 117 | 118 | The files in the cache were the ones used in the [JAGGRAB protocol](./JAGGRAB-Protocol.html) (i.e. files in cache 0 in old engine caches), 119 | map (mX_Y), and landscape (lX_Y) files. 120 | 121 | Incidentally, this naming is very similar to the names of the map and 122 | landscape files in new engine caches. 123 | 124 | ## \#317 Archive Format 125 | 126 | The old engine cache is made up two types of files. 127 | 128 | ### Data file 129 | 130 | The data file holds all of the files in the cache and is named 131 | `main_file_cache.dat`. 132 | It is therefore very big, typically ~10-20MB in size. 133 | 134 | ### Index file 135 | 136 | There are several index files, named `main_file_cache.idx` and 137 | then post-fixed with a number. 138 | Each index file holds 'pointers' to where a file is located in 139 | the main cache. 140 | Each index file represents a type of file. 141 | 142 | ### Index file format 143 | 144 | The index file is comprised of a collection of six byte blocks which hold 145 | information about where a file can be located in the data file. 146 | 147 | The format of a single block is as follows: 148 | ``` 149 | tribyte fileSize 150 | tribyte initialDataBlockId 151 | ``` 152 | 153 | ### Data file format 154 | 155 | The data file is comprised of a collection of 520 byte blocks. 156 | 157 | The format of each of these blocks is as follows: 158 | 159 | ``` 160 | short nextFileId 161 | short currentFilePartId 162 | tribyte nextDataBlockId 163 | byte nextFileTypeId 164 | byte[512] blockData 165 | ``` 166 | 167 | ### Running example 168 | 169 | Suppose, the client wishes to fetch file type 2, file id 17. 170 | 171 | First off, it will open the `main_file_cache.idx2` file and seek to the 172 | index `17 * 6` (102). 173 | It will then read the two tribytes: 174 | ``` 175 | fileSize = 1200 176 | intialDataBlockId = 4 177 | ``` 178 | 179 | The client will now open the `main_file_cache.dat` file and seek to the 180 | index `4 * 520` (2080). 181 | 182 | It will then read the following: 183 | ``` 184 | nextFileId = 17 185 | currentFilePartId = 0 186 | nextDataBlockId = 5 187 | nextFileTypeId = 2 188 | blockData = ... // 512 bytes of data 189 | ``` 190 | 191 | It will read the first 512 bytes of the file and then knows that there 192 | is 688 bytes left. 193 | 194 | Therefore, it has to read the next block: 195 | ``` 196 | nextFileId = 17 197 | currentFilePartId = 1 198 | nextDataBlockId = 6 199 | nextFileTypeId = 2 200 | blockData ... // 512 bytes of data 201 | ``` 202 | 203 | It reads these next 512 bytes of the file and now knows that there are 204 | 176 bytes left. 205 | 206 | So for a final time, it will read the next block: 207 | ``` 208 | nextFileId = 18 209 | currentFilePartId = 2 210 | nextDataBlockId = 7 211 | nextFileTypeId = 2 212 | blockData = ... // 176 bytes of data 213 | ``` 214 | 215 | It can ignore most of these values (the next ones are meaningless at 216 | this stage) and read the final 176 bytes. 217 | The whole 1200 byte file has now been read. 218 | -------------------------------------------------------------------------------- /src/Map-Region-System.md: -------------------------------------------------------------------------------- 1 | # Map region system 2 | 3 | A coordinate system is used to navigate through the RuneScape 4 | world. 5 | That coordinate system is based upon three variables, the absolute 6 | X-, Y-, and Z-coordinates. 7 | 8 | ## Definitions 9 | 10 | A **tile** is the in-game representation of an absolute coordinate. 11 | 12 | e.g. The coordinates `(3222, 3222)` represents one tile in the heart 13 | of the Lumbridge castle. 14 | 15 | A **chunk of tiles**, 8 x 8 in size. 16 | Also known as a region before the scope of a region was understood. 17 | The chunk is considered a point so it has X and Y coordinates. 18 | There are two forms of a Chunk: formatted and non-formatted, 19 | a formatted chunks equation is: 20 | 21 | ```java 22 | int chunkX = (getAbsoluteX() >> 3) - 6; 23 | int chunkY = (getAbsoluteY() >> 3) - 6; 24 | ``` 25 | 26 | This centers the chunk on the map, more on that later. 27 | 28 | The normal chunk equation is: 29 | 30 | ```java 31 | int chunkX = (getAbsoluteX() >> 3); 32 | int chunkY = (getAbsoluteY() >> 3); 33 | ``` 34 | 35 | e.g. For the coordinates `(3211, 3424)`, chunk X (formatted) is 395 and 36 | the chunk Y (un-formatted) is 428.'' 37 | 38 | ## Region 39 | 40 | A **region** is 64 x 64 in size, or 8 x 8 in chunks. 41 | The region is considered a point so it has X and Y coordinates. 42 | 43 | The equation for finding the region the coordinates is within is: 44 | 45 | ```java 46 | int regionX = (getUnformattedRegionX() >> 3); // getUnformatedRegionX() / 8; 47 | int regionY = (getUnformattedRegionY() >> 3); // getUnformatedRegionY() / 8; 48 | ``` 49 | 50 | e.g. For the coordinates `(3211, 3424)`, region X is 50, and the 51 | region Y is 53. 52 | 53 | Note: The Region X and Region Y coordinates are traditionally not used 54 | in server location calculations; but practical region systems should use 55 | this calculation for many purposes. 56 | 57 | ## Map 58 | 59 | There is no calculation for a map, and there is no Map X or Map Y. 60 | 61 | A Map is, however, a 104 x 104 area made up of 13 x 13 chunks. 62 | Why is the number not even you may ask? 63 | Because it has a center. 64 | The `(7, 7)` map chunk of the map is the center, and is also the formatted 65 | chunk. 66 | 67 | When a region update is called by the server, a new map is called, but you 68 | must understand that the formatted chunk never changes; the tiles in the 69 | map, however, are updated and trimmed. 70 | When the player moves out of the formatted chunk, the map is re-positioned 71 | to make that chunk the center yet again. 72 | As stated, a new update is not needed every time the player enters a 73 | new region, but when the range of +- 32 from the point in the center of 74 | the chunk is reached, an update is required to update the map to the 75 | new objects so that the 'black space' or fog is not reached. Confused? 76 | 77 | ## Diagram 78 | 79 | ![Diagram](./img/map-region-system-diagram.png) 80 | 81 | The active chunk is the chunk in which the player resides. 82 | The definite rendering chunks are the chunks in which will be rendered 83 | on the players screen no matter where they are in the active chunk. 84 | The indefinite rendering chunks are the chunks in which depending on 85 | where the player is within the active chunk they may be rendered or not. 86 | Remember this depends on the +- distance of 32 from the players 87 | absolute position. The queue chunks are pre-loaded chunks in whichafter the 88 | active chunk is moved may be disposed of or activated depending upon the 89 | direction in which the active chunk changes. 90 | 91 | ## Loading 92 | 93 | The following were the regions loaded for the coordinates `(3183, 3217)`: 94 | 95 | ![Loading diagram](./img/map-region-system-loading.png) 96 | 97 | If you can imagine a puzzle, a 64 x 64 piece does not fit equally within 98 | the 104 x 104 area. 99 | So, bits of each region are taken that are within the 104 x 104 map area. 100 | 101 | The amount of regions that are to be loaded can be calculated this way: 102 | 103 | Please note that Region X and Region Y are not formatted. 104 | 105 | ```java 106 | int amt = 0; 107 | 108 | for (int i21 = (player.getLocation().getRegionX() - 6) / 8; i21 <= (player.getLocation().getRegionX() + 6) / 8; i21++) { 109 | for (int k23 = (player.getLocation().getRegionY() - 6) / 8; k23 <= (player.getLocation().getRegionY() + 6) / 8; k23++) 110 | amt++; 111 | } 112 | ``` 113 | 114 | Along with this, the base X and base Y of each of the region can be 115 | calculated: 116 | 117 | ```java 118 | for (int i21 = (player.getLocation().getRegionX() - 6) / 8; i21 <= (player.getLocation().getRegionX() + 6) / 8; i21++) { 119 | for (int k23 = (player.getLocation().getRegionY() - 6) / 8; k23 <= (player.getLocation().getRegionY() + 6) / 8; k23++) 120 | System.out.println(i21 + " X " + (i21 << 6) + "," + k23 + " Y " + (k23 << 6));;; 121 | } 122 | ``` 123 | 124 | The 'X' and 'Y' coordinates represents the coordinates of the region as 125 | depicted in the diagram. After the regions are loaded they are trimmed 126 | to the tiles that are necessary. 127 | 128 | ## Example Location class 129 | 130 | The following is an example Location class written by sinisoul. 131 | It is not heavily commented due to it being a very simple class, 132 | and it should be easy to follow if you read this section in full. 133 | 134 | ```java 135 | package net.forge.content.world.node; 136 | 137 | /** 138 | * RuneForge (317) 139 | * @version 1.0.0 140 | * @author SiniSoul (SiniSoul@live.com) 141 | */ 142 | public final class Location { 143 | 144 | /** 145 | * The Tile X and Y coordinates. 146 | */ 147 | private int tilex = 0, 148 | tiley = 0; 149 | 150 | /** 151 | * The Height of the location. 152 | */ 153 | private int height = 0; 154 | 155 | /** 156 | * The asynchronous Chunk X and Y coordinates; used in region updating. 157 | */ 158 | private int chunkx = 0, 159 | chunky = 0; 160 | 161 | public void setTileX(int tilex) { 162 | this.tilex = (tilex & 0xFFFF); 163 | } 164 | 165 | public int getTileX() { 166 | return tilex; 167 | } 168 | 169 | public void setTileY(int tiley) { 170 | this.tiley = (tiley & 0xFFFF); 171 | } 172 | 173 | public int getTileY() { 174 | return tiley; 175 | } 176 | 177 | /** 178 | * @param formatted If the chunk is formatted for map positioning or 179 | * other formatted chunk comparison. 180 | */ 181 | public int calculateChunkX(boolean formatted) { 182 | return formatted ? (getTileX() >> 3) - 6 : (getTileX() >> 3); 183 | } 184 | 185 | /** 186 | * @param formatted If the chunk is formatted for map positioning or 187 | * other formatted chunk comparison. 188 | */ 189 | public int calculateChunkY(boolean formatted) { 190 | return formatted ? (getTileY() >> 3) - 6 : (getTileY() >> 3); 191 | } 192 | 193 | public void updateChunkX() { 194 | this.chunkx = calculateChunkX(true); 195 | } 196 | 197 | public void updateChunkY() { 198 | this.chunkx = calculateChunkY(true); 199 | } 200 | 201 | public int getChunkX() { 202 | return chunkx; 203 | } 204 | 205 | public int getMapLocalX() { 206 | return getTileX() - (getChunkX() << 3); 207 | } 208 | 209 | public int getChunkY() { 210 | return chunky; 211 | } 212 | 213 | public int getMapLocalY() { 214 | return getTileX() - (getChunkY() << 3); 215 | } 216 | 217 | public void setHeight(int height) { 218 | this.height = (height & 0x3); 219 | } 220 | 221 | public int getHeight() { 222 | return height; 223 | } 224 | 225 | public int getRegionX() { 226 | return calculateChunkX(false) >> 3; 227 | } 228 | 229 | public int getRegionLocalX() { 230 | return getTileX() - (getRegionX() << 6); 231 | } 232 | 233 | public int getRegionY() { 234 | return calculateChunkY(false) >> 3; 235 | } 236 | 237 | public int getRegionLocalY() { 238 | return getTileY() - (getRegionY() << 6); 239 | } 240 | 241 | public void set(int tilex, int tiley, int height) { 242 | setTileX(tilex); 243 | setTileY(tiley); 244 | setHeight(height); 245 | } 246 | 247 | public Location(int tilex, int tiley, int height) { 248 | set(tilex, tiley, height); 249 | updateChunkX(); 250 | updateChunkY(); 251 | } 252 | } 253 | ``` 254 | -------------------------------------------------------------------------------- /src/202-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RSC\]\] 2 | 3 | This page refers to the RSC \#202 client revision (the original 4 | distribution by eXemplar) 5 | 6 | == '''Packet structure''' == ? 7 | 8 | == '''Login''' == ? 9 | 10 | == '''Incoming Data''' == '''TODO:''' Document packet structures 11 |
 12 | #define IDX_WEIRD_USERNAME    32
 13 | #define IDX_LOGIN             0
 14 | #define IDO_LOGOUT_ACK        39                    // acknowledge logout command from server
 15 | #define IDO_PING              153                   // send ping to server, so it knows we're still there
 16 | #define IDO_IGNORE_ADD        25                    // add name to ignore list
 17 | #define IDO_IGNORE_REMOVE     108                   // remove name from ignore list
 18 | #define IDO_FRIENDS_ADD       168                   // add name to friends list
 19 | #define IDO_FRIENDS_REMOVE    52                    // remove name from friends list
 20 | #define IDO_PM_FRIEND         254                   // send pm to someone in friends list
 21 | #define IDO_SEND_CHAT         145
 22 | #define IDO_SEND_SERVER_CMD   90                    // sends a command to the server (type "::xxx" in chat and it sends command 'xxx')
 23 | #define IDO_UPDATE_SETTINGS   176                   // changes settings (chatblock, privateblock, tradeblock, duelblock)
 24 | 
 25 | #define IDO_LOGOUT            129
 26 | #define IDO_CHAR_DESIGN       218                   // send character design (makeover mage, creation)
 27 | #define IDO_SLEEPWORD         72
 28 | #define IDO_NEW_PLAYER_ACK    83                    // send ids of newly added player back to server, if it wants to
 29 | 
 30 | #define IDO_EXCEPTION_SEND    156
 31 | #define IDO_WALKCMD_1         246
 32 | #define IDO_WALKCMD_2         132
 33 | #define IDO_CLICKDIALOGITEM   154
 34 | #define IDO_SETCOMBATSTYLE    41
 35 | #define IDO_WITHDRAW          183
 36 | #define IDO_DEPOSIT           198
 37 | #define IDO_CLOSE_BANK        48
 38 | #define IDO_BUYITEM           128
 39 | #define IDO_SELLITEM          255
 40 | #define IDO_CLOSE_SHOP        253
 41 | #define IDO_CANCEL_TRADE      216
 42 | #define IDO_CONFIRM_TRADE     53
 43 | #define IDO_TRADE_UPDATE      70
 44 | #define IDO_ACCEPT_TRADE      211
 45 | #define IDO_DUEL_CONFIRM_1    87
 46 | #define IDO_DUEL_UPDATE       123
 47 | #define IDO_DUEL_FLAG_1       225
 48 | #define IDO_DUEL_FLAG_2       252
 49 | #define IDO_CANCEL_DUEL       35
 50 | #define IDO_PRAYER_OFF        248
 51 | #define IDO_PRAYER_ON         56
 52 | #define IDO_CHANGE_SETTINGS   157
 53 | 
 54 | // action commands...
 55 | #define IDO_CAST_GR_ITEM      104
 56 | #define IDO_USEWITH_GR_ITEM   34
 57 | #define IDO_TAKE_ITEM         245
 58 | #define IDO_CAST_WALLOBJ      67
 59 | #define IDO_USEWITH_WALLOBJ   36
 60 | #define IDO_WALLOBJ_CMD1      126
 61 | #define IDO_WALLOBJ_CMD2      235
 62 | #define IDO_CAST_OBJECT       17
 63 | #define IDO_USEWITH_OBJECT    94
 64 | #define IDO_OBJECT_CMD1       51
 65 | #define IDO_OBJECT_CMD2       40
 66 | 
 67 | #define IDO_CAST_INVITEM      49
 68 | #define IDO_USEWITH_INVITEM   27
 69 | #define IDO_REMOVE_ITEM       92
 70 | #define IDO_WEAR_ITEM         181
 71 | #define IDO_INVITEM_CMD       89
 72 | #define IDO_DROP_ITEM         147
 73 | 
 74 | #define IDO_CAST_NPC          71
 75 | #define IDO_USEWITH_NPC       142
 76 | #define IDO_TALK_NPC          177
 77 | #define IDO_NPC_CMD           74
 78 | #define IDO_ATTACK_NPC        73
 79 | 
 80 | #define IDO_CAST_PLAYER       55
 81 | #define IDO_USEWITH_PLAYER    16
 82 | #define IDO_ATTACK_PLAYER     57
 83 | #define IDO_DUEL_PLAYER       222
 84 | #define IDO_TRADE_PLAYER      166
 85 | #define IDO_FOLLOW_PLAYER     68
 86 | 
 87 | #define IDO_CAST_GROUND       232
 88 | #define IDO_CAST_SELF         206
 89 | 
 90 | #define IDO_REPORT_ABUSE      7
 91 | 
92 | 93 | 94 | 97 | 100 | 103 | 106 | 107 | 108 | 110 | 112 | 114 | 116 | 117 |
95 | opcode 96 | 98 | usage 99 | 101 | size 102 | 104 | payload 105 |
109 | 111 | 113 | 115 |
118 | == '''Outgoing Data''' == '''TODO:''' Document packet structures 119 |
120 | // login responses...
121 | #define IDX_MOD_ACCEPTED      25                    // logged in as player mod
122 | #define IDX_LOGIN_SUCCESS     0
123 | #define IDX_RELOGIN_SUCCESS   1                     // connection reestablished after lost connection...
124 | #define IDX_WRONG_PWD         3
125 | #define IDX_NAME_LOGGED_IN    4
126 | #define IDX_CLIENT_UPDATED    5
127 | #define IDX_IP_IN_USE         6
128 | #define IDX_LOGINS_EXCEEDED   7
129 | #define IDX_SERV_REJECTED     8
130 | #define IDX_LOGINSERV_REJCT   9
131 | #define IDX_NAME_IN_USE       10
132 | #define IDX_TEMP_DISABLED     11
133 | #define IDX_PERM_DISABLED     12
134 | #define IDX_SERVER_FULL       14
135 | #define IDX_MEMBERACC_REQ     15                    // requires member account to login here
136 | #define IDX_LOGINSERV_DOWN    16
137 | #define IDX_DECODE_FAIL       17
138 | #define IDX_LOGIN_MISMATCH    20
139 | 
140 | #define IDI_MESSAGE           48                    // (game) messages from server
141 | #define IDI_LOGOUT            222                   // logout command from server (forced, or initiated by client IDO_LOGOUT)
142 | #define IDI_LOGOUT_REJECT     136                   // not allowed to log out (e.g. when in combat)
143 | #define IDI_FRIENDS_LOAD      249                   // when logging in, sends the whole friends list to the client
144 | #define IDI_FRIEND_LOGGED     25                    // a friend from friends list logged in or out (also used to add a friend to friends list)
145 | #define IDI_IGNORE_LOAD       2                     // when logging in, sends the whole ignore list to the client
146 | #define IDI_SETTINGS_LOAD     158                   // load settings upon logging in (blocks)
147 | #define IDI_FRIENDS_PM        170                   // someone pm'd us
148 | 
149 | #define IDI_PLAYER_MOVEMENT   145                   // player movement update
150 | #define IDI_GRITEMS_UPDATE    109                   // update ground items
151 | #define IDI_OBJECTS_UPDATE    27
152 | #define IDI_INV_LOAD          114                   // load inventory
153 | #define IDI_PLAYER_UPDATE     53
154 | #define IDI_WALLOBJ_UPDATE    95
155 | #define IDI_NPC_MOVEMENT      77                    // npc movement update
156 | #define IDI_NPC_UPDATE        190
157 | #define IDI_DIALOG_SHOW       223
158 | #define IDI_DIALOG_CLOSE      127
159 | #define IDI_LOAD_NEWMAPAREA   131                   // entering a new region (maparea)
160 | #define IDI_XP_LOAD           180                   // load xp and stats
161 | #define IDI_EQUIP_UPDATE      177                   // equipment stats (armour, magic, prayer, weapaim/power)
162 | #define IDI_PLAYER_DIED       165
163 | #define IDI_LOADWORLD         115                   // load objects, wallobjects, items
164 | #define IDI_DESIGN_CHAR       207
165 | #define IDI_OPEN_TRADE_1      4
166 | #define IDI_CLOSE_TRADE       187
167 | #define IDI_TRADE_UPDATE      250                   // opponents offer was updated
168 | #define IDI_TRADE_B_UPDATE    92                    // update of opponents acception status
169 | #define IDI_SHOP_OPEN         253
170 | #define IDI_SHOP_CLOSE        220
171 | #define IDI_TRADE_A_UPDATE    18                    // update of thisplayers acception status
172 | #define IDI_LOAD_OPTIONS      152                   // camera angle, sound, mousebutton settings
173 | #define IDI_PRAYER            209
174 | #define IDI_QUESTS            224
175 | #define IDI_BANK_OPEN         93
176 | #define IDI_BANK_CLOSE        171
177 | #define IDI_XP_UPDATE         211
178 | #define IDI_OPEN_DUEL_1       229
179 | #define IDI_CLOSE_DUEL        160
180 | #define IDI_OPEN_TRADE_2      251                   // trade confirmation window
181 | #define IDI_DUEL_UPDATE       63                    // opponents offer was updated
182 | #define IDI_DUELOPT_UPDATE    198                   // update duel options
183 | #define IDI_BANK_UPDATE       139
184 | #define IDI_INV_ADD           228
185 | #define IDI_INV_REMOVE        191
186 | #define IDI_STAT_UPDATE       208
187 | #define IDI_DUEL_B_UPDATE     65                    // update of opponents acception status
188 | #define IDI_DUEL_A_UPDATE     197                   // update of thisplayers acception status
189 | #define IDI_OPEN_DUEL_2       147                   // duel confirmation window
190 | #define IDI_SOUND             11
191 | #define IDI_SPLASH            23
192 | #define IDI_WELCOMEWINDOW     248
193 | #define IDI_MESSAGE_1         148
194 | #define IDI_MESSAGE_2         64
195 | #define IDI_FATIGUE_UPDATE    126
196 | #define IDI_NEW_SLEEPWORD     219
197 | #define IDI_FATIGUE_SLEEPN    168                   // fatigue update in sleeping window
198 | #define IDI_SLEEP_SUCCESS     103
199 | #define IDI_SLEEP_FAILED      15
200 | #define IDI_SYSTEM_UPDATE     172
201 | 
202 | 203 | 204 | 207 | 210 | 213 | 216 | 217 | 218 | 220 | 222 | 224 | 226 | 227 |
205 | opcode 206 | 208 | usage 209 | 211 | size 212 | 214 | payload 215 |
219 | 221 | 223 | 225 |
228 | -------------------------------------------------------------------------------- /src/204-Protocol.md: -------------------------------------------------------------------------------- 1 | \[\[Category RSC\]\] 2 | 3 | This page refers to the RSC \#204 client revision, all of the opcodes 4 | are the same with the exception of the last three in the Outgoing Data 5 | section. 6 | 7 | == '''Packet structure''' == ? 8 | 9 | == '''Login''' == ? 10 | 11 | == '''Incoming Data''' == '''TODO:''' Document packet structures 12 |
 13 | #define IDX_WEIRD_USERNAME    32
 14 | #define IDX_LOGIN             0
 15 | #define IDO_LOGOUT_ACK        31                    // acknowledge logout command from server
 16 | #define IDO_PING              67                    // send ping to server, so it knows we're still there
 17 | #define IDO_IGNORE_ADD        132                   // add name to ignore list
 18 | #define IDO_IGNORE_REMOVE     241                   // remove name from ignore list
 19 | #define IDO_FRIENDS_ADD       195                   // add name to friends list
 20 | #define IDO_FRIENDS_REMOVE    167                   // remove name from friends list
 21 | #define IDO_PM_FRIEND         218                   // send pm to someone in friends list
 22 | #define IDO_SEND_CHAT         216
 23 | #define IDO_SEND_SERVER_CMD   38                    // sends a command to the server (type "::xxx" in chat and it sends command 'xxx')
 24 | #define IDO_UPDATE_SETTINGS   64                    // changes settings (chatblock, privateblock, tradeblock, duelblock)
 25 | 
 26 | #define IDO_LOGOUT            102
 27 | #define IDO_CHAR_DESIGN       235                   // send character design (makeover mage, creation)
 28 | #define IDO_SLEEPWORD         45
 29 | #define IDO_NEW_PLAYER_ACK    163                   // send ids of newly added player back to server, if it wants to
 30 | 
 31 | #define IDO_EXCEPTION_SEND    3
 32 | #define IDO_WALKCMD_1         16
 33 | #define IDO_WALKCMD_2         187
 34 | #define IDO_CLICKDIALOGITEM   116
 35 | #define IDO_SETCOMBATSTYLE    29
 36 | #define IDO_WITHDRAW          22
 37 | #define IDO_DEPOSIT           23
 38 | #define IDO_CLOSE_BANK        212
 39 | #define IDO_BUYITEM           236
 40 | #define IDO_SELLITEM          221
 41 | #define IDO_CLOSE_SHOP        166
 42 | #define IDO_CANCEL_TRADE      230
 43 | #define IDO_CONFIRM_TRADE     104
 44 | #define IDO_TRADE_UPDATE      46
 45 | #define IDO_ACCEPT_TRADE      55
 46 | #define IDO_DUEL_CONFIRM_1    77
 47 | #define IDO_DUEL_UPDATE       33
 48 | #define IDO_DUEL_FLAG_1       8
 49 | #define IDO_DUEL_FLAG_2       176
 50 | #define IDO_CANCEL_DUEL       197
 51 | #define IDO_PRAYER_OFF        254
 52 | #define IDO_PRAYER_ON         60
 53 | #define IDO_CHANGE_SETTINGS   111
 54 | 
 55 | // action commands...
 56 | #define IDO_CAST_GR_ITEM      249
 57 | #define IDO_USEWITH_GR_ITEM   53
 58 | #define IDO_TAKE_ITEM         247
 59 | #define IDO_CAST_WALLOBJ      180
 60 | #define IDO_USEWITH_WALLOBJ   161
 61 | #define IDO_WALLOBJ_CMD1      14
 62 | #define IDO_WALLOBJ_CMD2      127
 63 | #define IDO_CAST_OBJECT       99
 64 | #define IDO_USEWITH_OBJECT    115
 65 | #define IDO_OBJECT_CMD1       136
 66 | #define IDO_OBJECT_CMD2       79
 67 | 
 68 | #define IDO_CAST_INVITEM      4
 69 | #define IDO_USEWITH_INVITEM   91
 70 | #define IDO_REMOVE_ITEM       170
 71 | #define IDO_WEAR_ITEM         169
 72 | #define IDO_INVITEM_CMD       90
 73 | #define IDO_DROP_ITEM         246
 74 | 
 75 | #define IDO_CAST_NPC          50
 76 | #define IDO_USEWITH_NPC       135
 77 | #define IDO_TALK_NPC          153
 78 | #define IDO_NPC_CMD           202
 79 | #define IDO_ATTACK_NPC        190
 80 | 
 81 | #define IDO_CAST_PLAYER       229
 82 | #define IDO_USEWITH_PLAYER    113
 83 | #define IDO_ATTACK_PLAYER     171
 84 | #define IDO_DUEL_PLAYER       103
 85 | #define IDO_TRADE_PLAYER      142
 86 | #define IDO_FOLLOW_PLAYER     165
 87 | 
 88 | #define IDO_CAST_GROUND       158
 89 | #define IDO_CAST_SELF         137
 90 | 
 91 | #define IDO_REPORT_ABUSE      206
 92 | 
93 | 94 | 95 | 98 | 101 | 104 | 107 | 108 | 109 | 111 | 113 | 115 | 117 | 118 |
96 | opcode 97 | 99 | usage 100 | 102 | size 103 | 105 | payload 106 |
110 | 112 | 114 | 116 |
119 | == '''Outgoing Data''' == '''TODO:''' Document packet structures 120 |
121 | // login responses...
122 | #define IDX_MOD_ACCEPTED      25                    // logged in as player mod
123 | #define IDX_LOGIN_SUCCESS     0
124 | #define IDX_RELOGIN_SUCCESS   1                     // connection reestablished after lost connection...
125 | #define IDX_WRONG_PWD         3
126 | #define IDX_NAME_LOGGED_IN    4
127 | #define IDX_CLIENT_UPDATED    5
128 | #define IDX_IP_IN_USE         6
129 | #define IDX_LOGINS_EXCEEDED   7
130 | #define IDX_SERV_REJECTED     8
131 | #define IDX_LOGINSERV_REJCT   9
132 | #define IDX_NAME_IN_USE       10
133 | #define IDX_TEMP_DISABLED     11
134 | #define IDX_PERM_DISABLED     12
135 | #define IDX_SERVER_FULL       14
136 | #define IDX_MEMBERACC_REQ     15                    // requires member account to login here
137 | #define IDX_LOGINSERV_DOWN    16
138 | #define IDX_DECODE_FAIL       17
139 | #define IDX_LOGIN_MISMATCH    20
140 | 
141 | #define IDI_MESSAGE           131                   // (game) messages from server
142 | #define IDI_LOGOUT            4                     // logout command from server (forced, or initiated by client IDO_LOGOUT)
143 | #define IDI_LOGOUT_REJECT     183                   // not allowed to log out (e.g. when in combat)
144 | #define IDI_FRIENDS_LOAD      71                    // when logging in, sends the whole friends list to the client
145 | #define IDI_FRIEND_LOGGED     149                   // a friend from friends list logged in or out (also used to add a friend to friends list)
146 | #define IDI_IGNORE_LOAD       109                   // when logging in, sends the whole ignore list to the client
147 | #define IDI_SETTINGS_LOAD     51                    // load settings upon logging in (blocks)
148 | #define IDI_FRIENDS_PM        120                   // someone pm'd us
149 | 
150 | #define IDI_PLAYER_MOVEMENT   191                   // player movement update
151 | #define IDI_GRITEMS_UPDATE    99                    // update ground items
152 | #define IDI_OBJECTS_UPDATE    48
153 | #define IDI_INV_LOAD          53                    // load inventory
154 | #define IDI_PLAYER_UPDATE     234
155 | #define IDI_WALLOBJ_UPDATE    91
156 | #define IDI_NPC_MOVEMENT      79                    // npc movement update
157 | #define IDI_NPC_UPDATE        104
158 | #define IDI_DIALOG_SHOW       245
159 | #define IDI_DIALOG_CLOSE      252
160 | #define IDI_LOAD_NEWMAPAREA   25                    // entering a new region (maparea)
161 | #define IDI_XP_LOAD           156                   // load xp and stats
162 | #define IDI_EQUIP_UPDATE      153                   // equipment stats (armour, magic, prayer, weapaim/power)
163 | #define IDI_PLAYER_DIED       83
164 | #define IDI_LOADWORLD         211                   // load objects, wallobjects, items
165 | #define IDI_DESIGN_CHAR       59
166 | #define IDI_OPEN_TRADE_1      92
167 | #define IDI_CLOSE_TRADE       128
168 | #define IDI_TRADE_UPDATE      97                    // opponents offer was updated
169 | #define IDI_TRADE_B_UPDATE    162                   // update of opponents acception status
170 | #define IDI_SHOP_OPEN         101
171 | #define IDI_SHOP_CLOSE        137
172 | #define IDI_TRADE_A_UPDATE    15                    // update of thisplayers acception status
173 | #define IDI_LOAD_OPTIONS      240                   // camera angle, sound, mousebutton settings
174 | #define IDI_PRAYER            206
175 | #define IDI_QUESTS            5
176 | #define IDI_BANK_OPEN         42
177 | #define IDI_BANK_CLOSE        203
178 | #define IDI_XP_UPDATE         33
179 | #define IDI_OPEN_DUEL_1       176
180 | #define IDI_CLOSE_DUEL        225
181 | #define IDI_OPEN_TRADE_2      20                    // trade confirmation window
182 | #define IDI_DUEL_UPDATE       6                     // opponents offer was updated
183 | #define IDI_DUELOPT_UPDATE    30                    // update duel options
184 | #define IDI_BANK_UPDATE       249
185 | #define IDI_INV_ADD           90
186 | #define IDI_INV_REMOVE        123
187 | #define IDI_STAT_UPDATE       159
188 | #define IDI_DUEL_B_UPDATE     253                   // update of opponents acception status
189 | #define IDI_DUEL_A_UPDATE     210                   // update of thisplayers acception status
190 | #define IDI_OPEN_DUEL_2       172                   // duel confirmation window
191 | #define IDI_SOUND             204
192 | #define IDI_SPLASH            36
193 | #define IDI_WELCOMEWINDOW     182
194 | #define IDI_MESSAGE_1         89
195 | #define IDI_MESSAGE_2         222
196 | #define IDI_FATIGUE_UPDATE    114
197 | #define IDI_NEW_SLEEPWORD     117
198 | #define IDI_FATIGUE_SLEEPN    244                   // fatigue update in sleeping window
199 | #define IDI_SLEEP_SUCCESS     84
200 | #define IDI_SLEEP_FAILED      194
201 | #define IDI_SYSTEM_UPDATE     52
202 | 
203 | #define IDX_ACCOUNT_STOLEN    18                // "Account suspected stolen.", "Press 'recover a locked account' on front page."
204 | #define IDX_ACCOUNT_NOT_RSC   21                // "Unable to login.", "That is not an RS-Classic account"
205 | #define IDX_PASSWD_STOLEN     22                // "Password suspected stolen.", "Press 'change your password' on front page."
206 | 
207 | 208 | 209 | 212 | 215 | 218 | 221 | 222 | 223 | 225 | 227 | 229 | 231 | 232 |
210 | opcode 211 | 213 | usage 214 | 216 | size 217 | 219 | payload 220 |
224 | 226 | 228 | 230 |
233 | -------------------------------------------------------------------------------- /src/SUMMARY.md: -------------------------------------------------------------------------------- 1 | # Summary 2 | 3 | - [Home](./Home.md) 4 | - [About](./About.md) 5 | - [Rules](./Rules.md) 6 | - [IRC](./IRC.md) 7 | - [General disclaimer](./General-disclaimer.md) 8 | - [DMCA policy](./DMCA-policy.md) 9 | - [Privacy policy](./Privacy-policy.md) 10 | - [Data](./Data.md) 11 | - [Data-types](./Data-Types.md) 12 | - [ISAAC cipher](./ISAAC-cipher.md) 13 | - [Word](./Word.md) 14 | - [DWord](./DWord.md) 15 | - [QWord](./QWord.md) 16 | - [RS String](./RS-String.md) 17 | - [JAGGRAB protocol](./JAGGRAB-Protocol.md) 18 | - [Ondemand protocol](./Ondemand-Protocol.md) 19 | - [Archive format](./Archive-Format.md) 20 | - [OB3](./OB3.md) 21 | - [Client functions](./Client-functions.md) 22 | - [Map region system](./Map-Region-System.md) 23 | - [Censorship](./Censorship.md) 24 | - [Mouse coordinate tracking](./Mouse-coordinate-tracking.md) 25 | - [Class-Check](./Class-Check.md) 26 | - [RuneScape Protocol](./RuneScape-Protocol.md) 27 | - [Protocol #135](./135-Protocol.md) 28 | - [Protocol #194](./194-Protocol.md) 29 | - [Clear-screen](./194-Clear-screen.md) 30 | - [Logout](./194-Logout.md) 31 | - [Show-interface](./194-Show-interface.md) 32 | - [Protocol #202](./202-Protocol.md) 33 | - [Protocol #204](./204-Protocol.md) 34 | - [Items](./204-Items.md) 35 | - [NPCs](./204-NPCs.md) 36 | - [Objects](./204-Objects.md) 37 | - [Protocol #289](./289-Protocol.md) 38 | - [Construct-Map-Region](./289-Construct-Map-Region.md) 39 | - [Player-Dialogue-Head](./289-Player-Dialogue-Head.md) 40 | - [Send-Player-Head](./289-Send-Player-Head.md) 41 | - [Send-sidebar-interface](./289-Send-sidebar-interface.md) 42 | - [Protocol #317](./317/317-Protocol.md) 43 | - [Add-friend](./317/317-Add-friend.md) 44 | - [Add-ignore](./317/317-Add-ignore.md) 45 | - [Alternate-item-option-2](./317/317-Alternate-item-option-2.md) 46 | - [Animation-reset](./317/317-Animation-reset.md) 47 | - [Attack-(NPC)](./317/317-Attack-(NPC).md) 48 | - [Audio](./317/317-Audio.md) 49 | - [Bank-10-items](./317/317-Bank-10-items.md) 50 | - [Bank-5-items](./317/317-Bank-5-items.md) 51 | - [Bank-all-items](./317/317-Bank-all-items.md) 52 | - [Bank-X-items-part-1](./317/317-Bank-X-items-part-1.md) 53 | - [Bank-X-items-part-2](./317/317-Bank-X-items-part-2.md) 54 | - [Begin-player-updating](./317/317-Begin-player-updating.md) 55 | - [Button-click](./317/317-Button-click.md) 56 | - [Camera-movement](./317/317-Camera-movement.md) 57 | - [Camera-shake](./317/317-Camera-shake.md) 58 | - [Chat-interface-click](./317/317-Chat-interface-click.md) 59 | - [Chat-interface](./317/317-Chat-interface.md) 60 | - [Chat-settings](./317/317-Chat-settings.md) 61 | - [Clear-inventory](./317/317-Clear-inventory.md) 62 | - [Clear-screen](./317/317-Clear-screen.md) 63 | - [Close-window](./317/317-Close-window.md) 64 | - [Construct-map-region](./317/317-Construct-map-region.md) 65 | - [Create-Projectile](./317/317-Create-Projectile.md) 66 | - [Design-screen](./317/317-Design-screen.md) 67 | - [Display-hint-icon](./317/317-Display-hint-icon.md) 68 | - [Drop-item](./317/317-Drop-item.md) 69 | - [Enter-name](./317/317-Enter-name.md) 70 | - [Equip-item](./317/317-Equip-item.md) 71 | - [Flash-sidebar](./317/317-Flash-sidebar.md) 72 | - [Focus-change](./317/317-Focus-change.md) 73 | - [Follow](./317/317-Follow.md) 74 | - [Force-client-setting](./317/317-Force-client-setting.md) 75 | - [Friends-list-status](./317/317-Friends-list-status.md) 76 | - [Ground-Item-Action](./317/317-Ground-Item-Action.md) 77 | - [Hidden-Interface](./317/317-Hidden-Interface.md) 78 | - [Idle-logout](./317/317-Idle-logout.md) 79 | - [Idle](./317/317-Idle.md) 80 | - [Initialize-player](./317/317-Initialize-player.md) 81 | - [Input-amount](./317/317-Input-amount.md) 82 | - [Interface-animation](./317/317-Interface-animation.md) 83 | - [Interface-color](./317/317-Interface-color.md) 84 | - [Interface-item](./317/317-Interface-item.md) 85 | - [Interface-model-rotation](./317/317-Interface-model-rotation.md) 86 | - [Interface-offset](./317/317-Interface-offset.md) 87 | - [Interface-over-tab](./317/317-Interface-over-tab.md) 88 | - [Inventory-overlay](./317/317-Inventory-overlay.md) 89 | - [Item-action-1](./317/317-Item-action-1.md) 90 | - [Item-on-floor](./317/317-Item-on-floor.md) 91 | - [Item-on-item](./317/317-Item-on-item.md) 92 | - [Item-on-object](./317/317-Item-on-object.md) 93 | - [Item-on-player](./317/317-Item-on-player.md) 94 | - [Light-item](./317/317-Light-item.md) 95 | - [Loading-finished](./317/317-Loading-finished.md) 96 | - [Load-map-region](./317/317-Load-map-region.md) 97 | - [Logout](./317/317-Logout.md) 98 | - [Mage-NPC](./317/317-Mage-NPC.md) 99 | - [Magic-on-items](./317/317-Magic-on-items.md) 100 | - [Magic-on-player](./317/317-Magic-on-player.md) 101 | - [Minimap-State](./317/317-Minimap-State.md) 102 | - [Mouse-click](./317/317-Mouse-click.md) 103 | - [Move-item](./317/317-Move-item.md) 104 | - [Music](./317/317-Music.md) 105 | - [NPC-action-1](./317/317-NPC-action-1.md) 106 | - [NPC-action-2](./317/317-NPC-action-2.md) 107 | - [NPC-action-3](./317/317-NPC-action-3.md) 108 | - [NPC-Dialogue](./317/317-NPC-Dialogue.md) 109 | - [NPC-head-on-interface](./317/317-NPC-head-on-interface.md) 110 | - [Object-action-1](./317/317-Object-action-1.md) 111 | - [Object-action-2](./317/317-Object-action-2.md) 112 | - [Object-action-3](./317/317-Object-action-3.md) 113 | - [Object-removal](./317/317-Object-removal.md) 114 | - [Object-spawn](./317/317-Object-spawn.md) 115 | - [Open-chatbox-interface](./317/317-Open-chatbox-interface.md) 116 | - [Open-welcome-screen](./317/317-Open-welcome-screen.md) 117 | - [Pickup-ground-item](./317/317-Pickup-ground-item.md) 118 | - [Player-command](./317/317-Player-command.md) 119 | - [Player-head-to-interface](./317/317-Player-head-to-interface.md) 120 | - [Player-Option](./317/317-Player-Option.md) 121 | - [Play-song](./317/317-Play-song.md) 122 | - [Privacy-options](./317/317-Privacy-options.md) 123 | - [Region-change](./317/317-Region-change.md) 124 | - [Remove-friend](./317/317-Remove-friend.md) 125 | - [Remove-ignore](./317/317-Remove-ignore.md) 126 | - [Report-player](./317/317-Report-player.md) 127 | - [Reset-button-state](./317/317-Reset-button-state.md) 128 | - [Reset-camera](./317/317-Reset-camera.md) 129 | - [Reset-destination](./317/317-Reset-destination.md) 130 | - [Run-energy](./317/317-Run-energy.md) 131 | - [Scroll-position](./317/317-Scroll-position.md) 132 | - [Send-add-friend](./317/317-Send-add-friend.md) 133 | - [Send-add-ignore](./317/317-Send-add-ignore.md) 134 | - [Send-message](./317/317-Send-message.md) 135 | - [Send-private-message](./317/317-Send-private-message.md) 136 | - [Send-sidebar-interface](./317/317-Send-sidebar-interface.md) 137 | - [Send-Skill](./317/317-Send-Skill.md) 138 | - [Set-interface-text](./317/317-Set-interface-text.md) 139 | - [Show-interface](./317/317-Show-interface.md) 140 | - [Show-multi-combat](./317/317-Show-multi-combat.md) 141 | - [Show-tab](./317/317-Show-tab.md) 142 | - [Skill-level](./317/317-Skill-level.md) 143 | - [Song-Queue](./317/317-Song-Queue.md) 144 | - [System-update](./317/317-System-update.md) 145 | - [Trade-answer](./317/317-Trade-answer.md) 146 | - [Trade-request](./317/317-Trade-request.md) 147 | - [Unequip-item](./317/317-Unequip-item.md) 148 | - [Update-item-container](./317/317-Update-item-container.md) 149 | - [Walkable-interface](./317/317-Walkable-interface.md) 150 | - [Weight](./317/317-Weight.md) 151 | - [Protocol #357](./357-Protocol.md) 152 | - [Protocol #377](./377/377-Protocol.md) 153 | - [Animation-Reset](./377/377-Animation-Reset.md) 154 | - [Camera-Shake](./377/377-Camera-Shake.md) 155 | - [Construct-Map-Region](./377/377-Construct-Map-Region.md) 156 | - [Create-Static-Graphic](./377/377-Create-Static-Graphic.md) 157 | - [Initialize-Player](./377/377-Initialize-Player.md) 158 | - [Input-Amount](./377/377-Input-Amount.md) 159 | - [Interface-Animation](./377/377-Interface-Animation.md) 160 | - [Interface-Item](./377/377-Interface-Item.md) 161 | - [Inventory-Overlay](./377/377-Inventory-Overlay.md) 162 | - [Logout](./377/377-Logout.md) 163 | - [Move-Camera](./377/377-Move-Camera.md) 164 | - [Open-Welcome-Screen](./377/377-Open-Welcome-Screen.md) 165 | - [Play-Ambient-Wave](./377/377-Play-Ambient-Wave.md) 166 | - [Reset-Button-State](./377/377-Reset-Button-State.md) 167 | - [Reset-Ground-Items-and-Objects](./377/377-Reset-Ground-Items-and-Objects.md) 168 | - [Run-Energy](./377/377-Run-Energy.md) 169 | - [Send-Add-Friend](./377/377-Send-Add-Friend.md) 170 | - [Send-Ground-Item](./377/377-Send-Ground-Item.md) 171 | - [Send-Message](./377/377-Send-Message.md) 172 | - [Send-Sidebar-Interface](./377/377-Send-Sidebar-Interface.md) 173 | - [Send-Sound](./377/377-Send-Sound.md) 174 | - [Skill-Level](./377/377-Skill-Level.md) 175 | - [Walkable-Interface](./377/377-Walkable-Interface.md) 176 | - [Protocol #443](./443-Protocol.md) 177 | - [Protocol #464](./464-Protocol.md) 178 | - [Protocol #468](./468-Protocol.md) 179 | - [Protocol #474](./474-Protocol.md) 180 | - [Fourth-Interface-Option](./474-Fourth-Interface-Option.md) 181 | - [Remove-ignore](./474-Remove-ignore.md) 182 | - [Protocol #508](./508-Protocol.md) 183 | - [Protocol #634](./634-Protocol.md) 184 | - [Protocol #666](./666-Protocol.md) 185 | - [Protocol #668](./668-Protocol.md) 186 | - [Protocol #718](./718-Protocol.md) 187 | - [Close-window](./718-Close-window.md) 188 | - [Friends-packet](./718-Friends-packet.md) 189 | - [Interface](./718-Interface.md) 190 | - [Music-effect](./718-Music-effect.md) 191 | - [Open-URL](./718-Open-URL.md) 192 | - [Player-under-NPC-priority](./718-Player-under-NPC-priority.md) 193 | - [Protocol #742](./742-Protocol.md) 194 | --------------------------------------------------------------------------------