[bot] Implement CNetGame::Packet_ConnectAttemptFailed(...)

* Update `CNetGame::UpdateNetwork()`
This commit is contained in:
RD42 2024-06-01 18:44:36 +08:00
parent e4770acd44
commit 72ab40c2e2
2 changed files with 13 additions and 1 deletions

View File

@ -303,7 +303,9 @@ void CNetGame::UpdateNetwork()
case ID_MODIFIED_PACKET: case ID_MODIFIED_PACKET:
Packet_ModifiedPacket(pkt); Packet_ModifiedPacket(pkt);
break; break;
case ID_CONNECTION_ATTEMPT_FAILED:
Packet_ConnectAttemptFailed(pkt);
break;
case ID_CONNECTION_REQUEST_ACCEPTED: case ID_CONNECTION_REQUEST_ACCEPTED:
Packet_ConnectionSucceeded(pkt); Packet_ConnectionSucceeded(pkt);
break; break;
@ -399,6 +401,15 @@ void CNetGame::Packet_ModifiedPacket(Packet* packet)
{ {
} }
//----------------------------------------------------
// RST
void CNetGame::Packet_ConnectAttemptFailed(Packet* packet)
{
//logprintf("NPC: Connection attempt failed.");
exit(1);
}
//---------------------------------------------------- //----------------------------------------------------
// Connection Success // Connection Success

View File

@ -28,6 +28,7 @@ private:
void Packet_ConnectionBanned(Packet* packet); void Packet_ConnectionBanned(Packet* packet);
void Packet_DisconnectionNotification(Packet* packet); void Packet_DisconnectionNotification(Packet* packet);
void Packet_ModifiedPacket(Packet* packet); void Packet_ModifiedPacket(Packet* packet);
void Packet_ConnectAttemptFailed(Packet* packet);
void Packet_TrailerSync(Packet *p); void Packet_TrailerSync(Packet *p);
int m_iSpawnsAvailable; int m_iSpawnsAvailable;