This repository is a mirror of the .md files generated from the COPS X Emulator code (i.e. extracted from documentation on the various message types). Each .md file represents a version of the Conquer Online protocol that is supported by the COPS X Emulator (supporting 5016 to 5071 clients).
WARNING: COPS X Emulator is still in active development, and not all messages (even the ones fully reverse engineered) have been fully documented.
The layout of the messages are reverse engineered from both the leaked server binaries and the clients, and cross-referenced from the leaked EO source (while being careful about what has changed for CO2 or for EO post-fork). Many sources or Wiki entries have unknown, or even invalid, fields in the messages (which I contributed to in the past with some releases like COPS v6 Emulator).
This documentation, while limited to specific versions, should be much more accurate.
Each message is documented with its Type, its Length (in bytes) and a table of fields starting at offset 4 (after the standard headers).
Each field has an offset, type (see below), name and description (the later is the first line of the code documentation, and as such, may be incomplete).
NOTE: Deprecated / unused fields and actions are striked.
bool: A boolean encoded as a 8-bits integer (0 or 1 value).s8: A signed 8-bits integer.u8: An unsigned 8-bits integer.s16: A signed 16-bits integer.u16: An unsigned 16-bits integer.s32: A signed 32-bits integer.u32: An unsigned 32-bits integer.s64: A signed 64-bits integer.u64: An unsigned 64-bits integer.char[N]: A NUL-terminated string of at mostN - 1characters.byte[N]: A byte array of sizeN.StringPack[N]: A string pack using TQ format. If the number of strings is known,Nwill be a specific number.T[N]: An array of a nested structure (T).
Many sources or Wiki entries do not properly consider the padding, and wrongly enlarge some fields in messages. For example, it is typical for actions to be 16-bits, but end up being reported as 32-bits in other reference material due to padding.
The Conquer Online server was historically built with MSVC, for x86, using the default alignment (4) and no packing around message structures. This means that structures where typically aligned to 4 bytes (padded at the end), and also that fields are naturally aligned (i.e. a 32-bits integer following a 16-bits integer will still be aligned to 4 bytes, potentially adding padding in-between).
This documentation tries to clearly identify padding.
As this documentation is auto-generated and auto-mirrored, no manual edits of the .md files will be accepted. Also, no contributions for patches unsupported by COPS X Emulator will be accepted.
With that said, if you think some descriptions are unclear, or some messages and/or actions are wrong, please open an issue. For issues about wrong messages and/or actions, please backup your request with some reverse engineering proofs (and not just other public sources, that may just be wrong).
Being purely documentation, this repository is licensed under the Creative Commons (CC) license.
While not mandatory as per the CC license, please acknowledge my contributions to the Conquer Online developer scene if this documentation is used to build a Wiki entry or used to build an emulator.