GIGA REFACTOR

This commit is contained in:
2022-03-02 18:51:42 +01:00
parent 553b2f6aad
commit 6df59b1487
92 changed files with 1807 additions and 1785 deletions

View File

@@ -28,7 +28,7 @@ Connexion::Connexion(protocol::PacketDispatcher* dispatcher, network::TCPSocket&
}
bool Connexion::updateSocket() {
bool Connexion::UpdateSocket() {
if (m_Socket.GetStatus() != network::Socket::Connected)
return false;
@@ -47,13 +47,13 @@ bool Connexion::updateSocket() {
protocol::PacketType packetType;
decompressed >> packetType;
PacketPtr packet = protocol::PacketFactory::createPacket(packetType, decompressed);
PacketPtr packet = protocol::PacketFactory::CreatePacket(packetType, decompressed);
GetDispatcher()->Dispatch(packet);
}
return true;
}
bool Connexion::connect(const std::string& address, std::uint16_t port) {
bool Connexion::Connect(const std::string& address, std::uint16_t port) {
if (!m_Socket.Connect(address, port)) {
return false;
}
@@ -61,11 +61,11 @@ bool Connexion::connect(const std::string& address, std::uint16_t port) {
return true;
}
void Connexion::sendPacket(const protocol::Packet* packet) {
void Connexion::SendPacket(const protocol::Packet* packet) {
network::SendPacket(packet->Serialize(), m_Socket);
}
void Connexion::closeConnection() {
void Connexion::CloseConnection() {
m_Socket.Disconnect();
}