acesucks 1,311 Posted February 21, 2020 Report Share Posted February 21, 2020 Welcome Foreword Feel free to contribute to this thread. I hope we can bring this revision and the RSPS community as a whole to a new level by documenting as much as possible. Downloads This is the hidden content, please Sign In or Sign Up Item List (id, name) Object List (id, name) Login Breakdown Stage 0 (Client) This stage is called for disconnecting, for example when in Stage 6 a response code of 23 (No reply from loginserver) is received. Stage 1 (Client) The Client creates the connection Stage 2 (Client -> Server) The client writes 1 byte with value 14. Stage 3 (Server -> Client) The server sends 1 byte. If this byte is 0, the client proceeds to Stage 5 Stage 4 Stage 5 (Client -> Server) Part 1: Plain Data Type Value byte opcode (16/18) short login packet size int revision short RSA Block Size Part 2: RSA Encrypted Get bytes to an array the size of "RSA Block Size". Create a BigInteger from this Array. Decrypt that BigInt with modPow and wrap its ByteArray in a new ByteBuffer. Data Type Value byte Magic Value (always 1) byte authenticator type int xtea[0] int xtea[1] int xtea[2] int xtea[3] byte[8] authenticator code string password Authenticator Type Description Payload 0 TrustedComputer Input Int: Trusted Computer pointer_index + 4 1 Authenticator Code input. Medium_Int: Code pointer_index + 5 2 Indicates nothing will be received. pointer_index + 8 3 Authenticator Code input. Medium_Int: Code pointer_index + 5 *Note Type 0 isn't 100% known. *Note: Assuming Types 1 & 3 are for new inputs and 'trust this computer for 30 days' inputs Part 3: xtea Encrypted Data Type Value string username byte bitpacked of low memory and client resizability short width short height byte[24] random.dat data string key client parameter int affiliate id byte hardware details version(6) byte OS Type byte Architecture byte OS Version byte Vendor byte[4] ? short Max Memory byte Available Processors tribyte ? GJ2String[4] 4 empty GJ2 Strings? byte ? short ? GJ2String[2] ? (I use these for MAC & PCName) byte[2] ? int[4] 3 ints in a for loop & 1 seperate byte client parameter #2 int[16] crcs Stage 6 (Server -> Client) The server sends a response code. This value can be any of the following: Unexepected server responce please try using a different world. login to the game Invalid name/password banned username Account is already logged in try agian in 60 secs... Client has been updated! Please reload this page. This world is full. Please use a different world. Unable to connect. login server offline. Login limit exceeded. Too many connections from you address. Unable to connect. Bad session id. We suspect someone knows your password. Press 'change your password' on the front page. You need a members account to login to this world. Please subscribe, or use a different world. Could not complete login. Please try using a different world. The server is being updated. Please wait 1 minute and try again. See here Too many incorrect longs from your address. Please wait 5 minutes before trying again. You are standing in a members-only area. To play on this world move to a free area first. Account locked as we suspect it has been stolen. Press 'recover a locked account' on front page. This world is running a closed beta. sorry invited players only. please use a different world. Invalid loginserver requested please try using a different world. You have only just left another world. your profile will be transferred in xxx seconds. Malformed login packet. Please try agian. No reply from loginserver. Please wait 1minute and try again. Error loading your profile. please contact customer support. Unexepected loginserver response This computers address has been blocked as it was used to break our rules. Service unavailable. 56. Authenticator Login. As you can see this is a response to the data gathered in from Stage 5. Most of the response codes will lead to going to Stage 0 and thus disconnecting from the server. The only exceptions are: when the response code is 2, the client will immediately go to Stage 9. This is the normal flow when someone logs in 100% correctly. when the response code is 21, the client will go to Stage 7 Stage 7 (Server -> Client) When the player just left another world. The server sends a byte containing the time for the client to wait to reconnect. The client then proceeds to Stage 8 Stage 9 Data Type Description Byte Trusted Computer ? (0,1) Byte Trusted 1 Byte Trusted 2 Byte Trusted 3 Byte Trusted 4 Byte Player Rights (0,1,2) Byte some boolean? Short Player Index Byte members ? dunno "Packet" Packet ID (Load map region) Ushort Packet Size Stage 10 Game Packets Server -> Client 14 Set skill level & exp Data Type Description UByte Level UByteA Skill ID UByteS Experience 25 Object Spawn? Data Type Description UShortA UShort UByteS Object Type 95 ? Data Type Description ByteS ByteA ULEShort UShortA ULEShort ByteS method_ap_byte ULEShort UShortA UShort 113 Camera Data Type Description UByte X UByte Y UShort Zmodifier UByte UByte Distance? >=100 127 Ground item... Data Type Description UByte UShort UShort UShort 239 Data Type Description UByte UShort UByte UShort 200 Spawn ground item Data Type Description UByte UByte 239 Data Type Description UByte UShort UByte UShort Cache Index Files There are 16 index files [0-15] and one reference file [255]. Value Data 0 Skeleton 1 Skins 2 Config 3 Interfaces 4 Sound Effects (1) 5 Landscape 6 Music (1) 7 Models 8 Sprites 9 Textures 10 Huffman 11 Music (2) 12 Client Scripts 13 Fonts Parent 14 Sound Effects (2) 15 Sound Effects (3) Config The config index file contains data on the following: Config File # Data 1 Underlay Definitions 2 3 IdentityKit 4 Overlay Definitions 5 Inv Definitions 6 Object Definitions 8 Enum Definitions 9 NPC Definitions 10 Item Definitions 12 Animation (Sequence) Definitions 13 AnimatedGraphics (SpotAnim/GFX) Definitions 14 VarpBit Definitions 15 16 Varp Definitions 2 Link to comment Share on other sites More sharing options...
Draynor 1,063 Posted March 9, 2020 Report Share Posted March 9, 2020 This is for #83 so quite old but does the job Link to comment Share on other sites More sharing options...
[email protected] 0 Posted March 15, 2020 Report Share Posted March 15, 2020 Thx this is very informative Link to comment Share on other sites More sharing options...
Kobra 0 Posted March 30, 2020 Report Share Posted March 30, 2020 Really awesome breakdown, thanks for the useful info Link to comment Share on other sites More sharing options...
prosperity 0 Posted April 1, 2020 Report Share Posted April 1, 2020 Thanks, this is really interesting and well explained. Link to comment Share on other sites More sharing options...
Hunter 1 Posted April 18, 2020 Report Share Posted April 18, 2020 Very informative. A great post for new people who are unfamiliar with client side work. Link to comment Share on other sites More sharing options...
Taz2307 1 Posted April 18, 2020 Report Share Posted April 18, 2020 nice!# message2shortslol #lovethiscommunitybaby Link to comment Share on other sites More sharing options...
Samoth1232 0 Posted May 24, 2020 Report Share Posted May 24, 2020 thx ima use this seems intresting Link to comment Share on other sites More sharing options...
steef 0 Posted November 20, 2021 Report Share Posted November 20, 2021 Thanks! Link to comment Share on other sites More sharing options...
Anastasia 0 Posted November 29, 2021 Report Share Posted November 29, 2021 Thanks! Very useful information! Link to comment Share on other sites More sharing options...
Aqua Berry 1 Posted December 1, 2021 Report Share Posted December 1, 2021 thanks gonna use this alot Link to comment Share on other sites More sharing options...
alkaline3030 0 Posted February 2, 2022 Report Share Posted February 2, 2022 thank you very much Link to comment Share on other sites More sharing options...
DarkScape 0 Posted February 12, 2022 Report Share Posted February 12, 2022 niceeeeeeee!!21!@@!@@!@!!@!#$!$#!@@e32qùwedgfefqwf Link to comment Share on other sites More sharing options...
chefcurry 0 Posted March 9, 2022 Report Share Posted March 9, 2022 Really helps, thanks Link to comment Share on other sites More sharing options...
strelocked 0 Posted March 31, 2022 Report Share Posted March 31, 2022 thanks! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now