API Documentation
Table of Contents
Namespaces
Functions
- interleave() : void
- Interleaves a sequence of bytes. When encrypting EO data, bytes are "woven" into each other.
- deinterleave() : void
- Deinterleaves a sequence of bytes. This is the reverse of interleave.
- flipMsb() : void
- Flips the most significant bits of each byte in a sequence of bytes.
- swapMultiples() : void
- Swaps the order of contiguous bytes in a sequence that are divisible by a given multiple value.
- serverVerificationHash() : int
- This hash function is used by the game client to verify communication with a genuine server during connection initialization.
- _mod() : int
- Performs a modulus operation, considering negative adjustments.
Functions
interleave()
Interleaves a sequence of bytes. When encrypting EO data, bytes are "woven" into each other.
interleave(array<string|int, int> &$data) : void
This is an in-place operation.
Parameters
- $data : array<string|int, int>
-
Reference to the data to interleave.
deinterleave()
Deinterleaves a sequence of bytes. This is the reverse of interleave.
deinterleave(array<string|int, int> &$data) : void
This is an in-place operation.
Parameters
- $data : array<string|int, int>
-
Reference to the data to deinterleave.
flipMsb()
Flips the most significant bits of each byte in a sequence of bytes.
flipMsb(array<string|int, int> &$data) : void
Values 0 and 128 are not flipped.
Parameters
- $data : array<string|int, int>
-
Reference to the data to flip MSB on.
swapMultiples()
Swaps the order of contiguous bytes in a sequence that are divisible by a given multiple value.
swapMultiples(array<string|int, int> &$data, int $multiple) : void
Parameters
- $data : array<string|int, int>
-
Reference to the data to swap bytes in.
- $multiple : int
-
The multiple value.
serverVerificationHash()
This hash function is used by the game client to verify communication with a genuine server during connection initialization.
serverVerificationHash(int $challenge) : int
Parameters
- $challenge : int
-
The challenge value sent by the client. Should be no larger than 11,092,110.
Tags
Return values
int —The hashed challenge value.
_mod()
Performs a modulus operation, considering negative adjustments.
_mod(int $a, int $b) : int
Parameters
- $a : int
-
The dividend.
- $b : int
-
The divisor.
Return values
int —The result of the modulus operation.