Class PlayerCache

Class Documentation

class core::cache::PlayerCache

Public Functions

PlayerCache(std::shared_ptr<Redis> redis, std::shared_ptr<mysql::MySQL> database)
~PlayerCache()
uint32_t GenerateLoginKey(uint32_t accountId)
uint32_t CheckLoginKey(uint32_t loginKey)
void RemoveLoginKeyTTL(uint32_t loginKey)
void SetLoginKeyTTL(uint32_t loginKey)
void GetPlayer(uint32_t playerId, const std::function<void(Player)> &cb)
void SetTeleportationPosition(uint32_t playerId, int32_t x, int32_t y)
void SavePlayer(const Player &player)
void GetPlayers(uint32_t accountId, const std::function<void(const std::vector<uint32_t>&)> &cb)
void AddPlayer(uint32_t accountId, uint32_t playerId, uint8_t slot)