|
eolib 0.5.0
A core C library for writing applications related to Endless Online
|
Go to the source code of this file.
Functions | |
| EoSequencer | eo_sequencer_init (int32_t start) |
| EoResult | eo_sequencer_next (EoSequencer *sequencer, int32_t *out_value) |
| int32_t | eo_generate_sequence_start () |
| int32_t | eo_sequence_start_from_init (int32_t s1, int32_t s2) |
| int32_t | eo_sequence_start_from_ping (int32_t s1, int32_t s2) |
| EoResult | eo_sequence_init_bytes (int32_t start, uint8_t *out_bytes) |
| EoResult | eo_sequence_ping_bytes (int32_t start, uint8_t *out_bytes) |
| int32_t eo_generate_sequence_start | ( | void | ) |
Generates a cryptographically random starting value for a sequencer.
Definition at line 29 of file sequencer.c.
| EoResult eo_sequence_init_bytes | ( | int32_t | start, |
| uint8_t * | out_bytes ) |
Initializes a sequence of bytes based on the starting value.
| start | The starting value for the sequence. |
| out_bytes | A pointer to the buffer where the initialized byte sequence will be stored. Must have space for at least 2 bytes. |
Definition at line 46 of file sequencer.c.
| EoResult eo_sequence_ping_bytes | ( | int32_t | start, |
| uint8_t * | out_bytes ) |
Generates a sequence of bytes for the ping packet based on the starting value.
| start | The starting value for the sequence. |
| out_bytes | A pointer to the buffer where the ping byte sequence will be stored. Must have space for at least 2 bytes. |
Definition at line 87 of file sequencer.c.
| int32_t eo_sequence_start_from_init | ( | int32_t | s1, |
| int32_t | s2 ) |
Calculates the starting sequence value based on the initial server sequence values.
| s1 | The first sequence value from the server. |
| s2 | The second sequence value from the server. |
Definition at line 34 of file sequencer.c.
| int32_t eo_sequence_start_from_ping | ( | int32_t | s1, |
| int32_t | s2 ) |
Calculates the starting sequence value based on the ping sequence values.
| s1 | The first sequence value from the server ping response. |
| s2 | The second sequence value from the server ping response. |
Definition at line 41 of file sequencer.c.
| EoSequencer eo_sequencer_init | ( | int32_t | start | ) |
Initializes a sequencer with the given starting value.
| start | The initial value for the sequencer. |
Definition at line 5 of file sequencer.c.
| EoResult eo_sequencer_next | ( | EoSequencer * | sequencer, |
| int32_t * | out_value ) |
Gets the next value in the sequence, advances the counter, and writes it to out_value.
| sequencer | The sequencer to advance. |
| out_value | Output for the next sequence value. May be NULL to advance without capturing the value. |
Definition at line 13 of file sequencer.c.