EQU8 Documentation
  • Welcome
  • Integration Guide
    • Examples
    • Download SDK & copy files
    • Server-side configuration
    • Unique identifier & reading user
    • Accepting player and data
    • Polling server events
    • Client-side Configuration
    • Receiving data from the server
    • Polling client events
    • Protecting game resources
    • Protection template file-format
    • Protection Template Example
    • Renaming EQU8 Launcher
    • Configuring EQU8 Launcher
    • Distributing with EQU8
  • Errors
    • Error Status codes
Powered by GitBook
On this page

Was this helpful?

  1. Integration Guide

Receiving data from the server

Again much like with the server-code, the client must also be able to send and receive data. The integration for the client-side is identical to the one in the server.

Lets start with receiving data sent from the server.

C/C++

std::unique_ptr<packet> p{serialize_packet(buf, len)};
if(packet_type::equ8_data == p->id)
{
    auto equ8 = static_cast<const packet_equ8_data *>(p.get());
    equ8_client_on_data_received(equ8->data, equ8->size);
}
packet p = Packet.serialize_packet(data);
if(packet_type.equ8_data == p.id)
{
    var s = ((packet_equ8_data)p);
    equ8.client.on_data_received(s.data);
}
PreviousClient-side ConfigurationNextPolling client events

Last updated 4 years ago

Was this helpful?