GIGA REFACTOR
This commit is contained in:
@@ -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();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user