flygard-core/deps/libsidecar/stub/player-interactions-api.h
Anton Popovichenko 6f0ba8e896
feat(Core): Add clustering support (#16832)
Co-authored-by: 3kynox <thierry.prost@gmail.com>
Co-authored-by: nox <nox@noxen.net>
Co-authored-by: Ludwig <sudlud@users.noreply.github.com>
2026-07-27 18:51:04 +02:00

34 lines
1.4 KiB
C

#ifndef __PLAYER_INTERACTIONS_API__
#define __PLAYER_INTERACTIONS_API__
#include <stdint.h>
#include <stdbool.h>
#include <stdlib.h>
typedef enum PlayerInteractionErrorCode {
PlayerInteractionErrorCodeNoError = 0,
PlayerInteractionErrorCodeNoHandler = 1,
PlayerInteractionErrorCodeCodePlayerNotFound = 2,
} PlayerInteractionErrorCode;
// CanPlayerInteractWithNPCAndFlags request.
typedef struct {
int errorCode;
bool canInteract;
} CanPlayerInteractWithNPCAndFlagsResponse;
typedef CanPlayerInteractWithNPCAndFlagsResponse (*CanPlayerInteractWithNPCAndFlagsHandler) (uint64_t /*playerGUID*/, uint64_t /*npcGUID*/, uint32_t /*npcFlags*/);
void SetCanPlayerInteractWithNPCAndFlagsHandler(CanPlayerInteractWithNPCAndFlagsHandler h);
CanPlayerInteractWithNPCAndFlagsResponse CallCanPlayerInteractWithNPCAndFlagsHandler(uint64_t player_guid, uint64_t npc_guid, uint32_t npc_flags);
// CanPlayerInteractWithGOAndType request.
typedef struct {
int errorCode;
bool canInteract;
} CanPlayerInteractWithGOAndTypeResponse;
typedef CanPlayerInteractWithGOAndTypeResponse (*CanPlayerInteractWithGOAndTypeHandler) (uint64_t /*playerGUID*/, uint64_t /*goGUID*/, uint8_t /*goType*/);
void SetCanPlayerInteractWithGOAndTypeHandler(CanPlayerInteractWithGOAndTypeHandler h);
CanPlayerInteractWithGOAndTypeResponse CallCanPlayerInteractWithGOAndTypeHandler(uint64_t player_guid, uint64_t go_guid, uint8_t go_type);
#endif