dusk/src/packet/packetping.h

28 lines
619 B
C

/**
* Copyright (c) 2025 Dominic Masters
*
* This software is released under the MIT License.
* https://opensource.org/licenses/MIT
*/
#pragma once
#include "error/error.h"
typedef struct {
int32_t number;
} packetping_t;
/**
* Creates a ping packet.
*
* @param packet Pointer to the packet structure to initialize.
*/
void packetPingCreate(packet_t *packet);
/**
* Handles a ping packet received FROM a server INTO a client.
*
* @param packet Pointer to the packet structure to handle.
* @return ERROR_OK on success, or an error code on failure.
*/
errorret_t packetPingClient(packet_t *packet);