User Tools

Site Tools


gamedev:remotelaunching:networkprotocol

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
gamedev:remotelaunching:networkprotocol [2024/11/26 17:19] – [File Data Received] dragonlordgamedev:remotelaunching:networkprotocol [2024/12/09 13:30] (current) dragonlord
Line 52: Line 52:
 ===== Response File Layout ===== ===== Response File Layout =====
  
-Send by the client in response to a [[#request_file_layout|Request File Layout]] message containing the scanned file layout. For each file one message is sent. The message is send reliable and has this format:+Send by the client in response to a [[#request_file_layout|Request File Layout]] message containing the scanned file layout. The message is send reliable and has this format:
  
 ^  Type  ^  Name  ^  Description  ^ ^  Type  ^  Name  ^  Description  ^
 | [[gamedev:dnp#data_types|Byte]] | Code  | Message code. Is value ''4'' | | [[gamedev:dnp#data_types|Byte]] | Code  | Message code. Is value ''4'' |
-| [[gamedev:dnp#data_types|Byte]] | Flags <WRAP>Flags. Can be a combination of one or more of these bits: +| [[gamedev:dnp#data_types|UInt]] | Count Count of file entries| 
-  * ''1'': Finish file layout+| FileInfo | Files[Count] | File information. | 
-  * ''2'': File layout is empty. The file information contained in this message is invalidUsed together with ''1''. +|  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. 
-</WRAP> |+ 
 +Where ''FileInfo'' is: 
 +^  Type  ^  Name  ^  Description  ^
 | [[gamedev:dnp#data_types|String16]] | Path | File path relative to root of data directory. | | [[gamedev:dnp#data_types|String16]] | Path | File path relative to root of data directory. |
 | [[gamedev:dnp#data_types|ULong]] | Size | File size in bytes. | | [[gamedev:dnp#data_types|ULong]] | Size | File size in bytes. |
 | [[gamedev:dnp#data_types|String8]] | Hash | Hash of file (SHA-256). | | [[gamedev:dnp#data_types|String8]] | Hash | Hash of file (SHA-256). |
-|  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. | 
  
 ===== Request File Block Hashes ===== ===== Request File Block Hashes =====
Line 78: Line 79:
 ===== Response File Block Hashes ===== ===== Response File Block Hashes =====
  
-Send by the client in response to a [[#request_file_block_hashes|Request File Block Hashes]] message containing the file block hashes. Each message contains one block. The blocks are send in order from first to last. The message is send reliable and has this format:+Send by the client in response to a [[#request_file_block_hashes|Request File Block Hashes]] message containing the file block hashes. The message is send reliable and has this format:
  
 ^  Type  ^  Name  ^  Description  ^ ^  Type  ^  Name  ^  Description  ^
 | [[gamedev:dnp#data_types|Byte]] | Code  | Message code. Is value ''6'' | | [[gamedev:dnp#data_types|Byte]] | Code  | Message code. Is value ''6'' |
 | [[gamedev:dnp#data_types|String16]] | Path | File path relative to root of data directory. | | [[gamedev:dnp#data_types|String16]] | Path | File path relative to root of data directory. |
-| [[gamedev:dnp#data_types|Byte]] | Flags <WRAP>Flags. Can be a combination of one or more of these bits: +| [[gamedev:dnp#data_types|UInt]] | Count Count of blocks. | 
-  * 1: Finish block hashes. +BlockInfo Blocks[Count] | Blocks in file order. |
-  * 2: No blocks. The block information contained in this message is invalid. Used together with 1. +
-</WRAP> +
-[[gamedev:dnp#data_types|UInt]] | Index | Index of block. | +
-| [[gamedev:dnp#data_types|String8]] | Hash | Block hash (SHA-256). |+
 |  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. | |  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. |
 +
 +Where ''BlockInfo'' is:
 +^  Type  ^  Name  ^  Description  ^
 +| [[gamedev:dnp#data_types|String8]] | Hash | Block hash (SHA-256). |
  
 ===== Request Delete File ===== ===== Request Delete File =====
Line 152: Line 153:
 | [[gamedev:dnp#data_types|String16]] | Path | File path relative to root of data directory. | | [[gamedev:dnp#data_types|String16]] | Path | File path relative to root of data directory. |
 | [[gamedev:dnp#data_types|UInt]] | Block | Index of block to write the data to. | | [[gamedev:dnp#data_types|UInt]] | Block | Index of block to write the data to. |
-| [[gamedev:dnp#data_types|Byte]] | Flags | <WRAP>Flags. Can be a combination of one or more of these bits: 
-  * ''1'': Finish block. 
-</WRAP> | 
 | [[gamedev:dnp#data_types|Byte]][*] | Data | Remaining bytes in the message is the data to write to the block. | | [[gamedev:dnp#data_types|Byte]][*] | Data | Remaining bytes in the message is the data to write to the block. |
  
Line 167: Line 165:
 | [[gamedev:dnp#data_types|UInt]] | Block | Index of block that has been written to. | | [[gamedev:dnp#data_types|UInt]] | Block | Index of block that has been written to. |
 | [[gamedev:dnp#data_types|Byte]] | Result | <WRAP>Result of write operation. Can be one of these values: | [[gamedev:dnp#data_types|Byte]] | Result | <WRAP>Result of write operation. Can be one of these values:
-  * ''0'': Writing data has been successful. Send after receiving part with finish flag set.+  * ''0'': Writing data has been successful.
   * ''1'': Writing data has failed.   * ''1'': Writing data has failed.
 Additional result codes can be added in the future to indicate better what has been the problem. Servers have to consider all values except ''0'' as a failure.</WRAP> | Additional result codes can be added in the future to indicate better what has been the problem. Servers have to consider all values except ''0'' as a failure.</WRAP> |
Line 237: Line 235:
 | [[gamedev:dnp#data_types|String8]] | Timestamp | Timestamp in text form. | | [[gamedev:dnp#data_types|String8]] | Timestamp | Timestamp in text form. |
 | [[gamedev:dnp#data_types|String16]] | Message | Log message. | | [[gamedev:dnp#data_types|String16]] | Message | Log message. |
 +|  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. |
 +
 +
 +===== Request System Property =====
 +
 +Send by the server to request information about the system the client is running on. The server indicates which property to query. The client has to return the requested property value if it is supported and the value can be determined. Otherwise the client has to return an empty response. The message is send reliable and has this format:
 +
 +^  Type ^  Name  ^  Description  ^
 +| [[gamedev:dnp#data_types|Byte]] | Code | Message code. Is value ''18'' |
 +| [[gamedev:dnp#data_types|String8]] | Property | <WRAP>Name of property to query. Can be one of these values:
 +  * ''properties.names'': List of all properties supported by the client. The server can safely query any of these properties. This is the only property name the client has to support.
 +  * ''profiles.names'': List of launcher profile names. 
 +  * ''profiles.default'': Name of default profile or empty string if there is none.
 +Additional property names can be added in the future. Applications can define custom property names. Clients have to return empty value for unknown properties.</WRAP> |
 +|  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. |
 +
 +The client sends back a [[#response_system_property|Response System Property]] message.
 +
 +===== Response System Property =====
 +
 +Send by the client in response to a [[#request_system_property|Request System Property]] message. The response contains the property value if the client supports the property and can determine the value. Otherwise the client sends an response with empty data. The message is send reliable and has this format:
 +
 +^  Type  ^  Name  ^  Description  ^
 +| [[gamedev:dnp#data_types|Byte]] | Code  | Message code. Is value ''19'' |
 +| [[gamedev:dnp#data_types|String8]] | Property | Same value as ''Property'' in request. |
 +| [[gamedev:dnp#data_types|Strgin16]] | PropertyData | <WRAP>Value of property depending of type or empty if not supported.
 +The length and format of ''PropertyData'' depends on the property type.
 +  * ''properties.names'': Newline separated list of property names. For example ''Profile A\nProfile B''.
 +  * ''profiles.names'': Newline separated list of profile names. For example ''Profile A\nProfile B''.
 +  * ''profiles.default'': Name of default profile or empty string if there is none.
 +Additional property names can be added in the future. Applications can define custom property names. Clients have to return empty value for unknown properties.</WRAP> |
 +|  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. |
 +
 +===== Keep-Alive =====
 +
 +Send by the server and the client to verify the other side is still alive. This catches situations where the other side crashed or the network connection between the two sides ruptured. This messages requires no response since it is send reliable. Failure to receive it closes the connection. The message has this format:
 +
 +^  Type ^  Name  ^  Description  ^
 +| [[gamedev:dnp#data_types|Byte]] | Code | Message code. Is value ''20'' |
 |  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. | |  -  | Reserved | Reserved for future expansion. Ignore any additional bytes in the message. |
  
gamedev/remotelaunching/networkprotocol.1732641558.txt.gz · Last modified: 2024/11/26 17:19 by dragonlord