Reinitialized project to reduce the git branch size
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
#include <tommath.h>
|
||||
#include <misc/endianness.h>
|
||||
#include <Definitions.h>
|
||||
#include <log/LogUtils.h>
|
||||
#include "../../InstanceHandler.h"
|
||||
#include "VoiceClient.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace ts::server;
|
||||
using namespace ts::protocol;
|
||||
|
||||
extern InstanceHandler* serverInstance;
|
||||
|
||||
void VoiceClient::sendPingRequest() {
|
||||
this->lastPingRequest = std::chrono::system_clock::now();
|
||||
|
||||
auto packet = make_shared<ServerPacket>(PacketTypeInfo::Ping, pipes::buffer_view{});
|
||||
packet->enable_flag(PacketFlag::Unencrypted);
|
||||
this->connection->sendPacket(packet, false, true); /* prepare directly so the packet gets a packet id */
|
||||
|
||||
this->lastPingId = packet->packetId();
|
||||
|
||||
#ifdef PKT_LOG_PING
|
||||
logMessage(this->getServerId(), "{}[Ping] Sending a ping request with it {}", CLIENT_STR_LOG_PREFIX, this->lastPingId);
|
||||
#endif
|
||||
}
|
||||
Reference in New Issue
Block a user