- add: ability to refresh the current session

- add: delete type to delete character request
- add: ability to update key in redis
- add: handle alive packet to refresh the session
- fix: delete now actually returns the time remaining correctly
- fix: character list now has the correct time until character deletion
This commit is contained in:
2025-01-08 02:03:27 -05:00
parent 584892ab97
commit 6d35d15ac3
16 changed files with 158 additions and 25 deletions

View File

@@ -60,8 +60,8 @@ impl PacketRouter {
pub async fn route_packet(&self, stream: &mut TcpStream, packet: Packet, connection_id: String) -> Result<(), Box<dyn Error + Send + Sync>> {
debug!("Routing packet: {:?}", packet);
match packet.packet_type {
PacketType::PakcsAlive => Ok(()),
// Generic Server Packets
PacketType::PakcsAlive => auth::handle_alive_req(stream, packet, self.auth_client.clone(), self.connection_service.clone(), connection_id).await,
PacketType::PakcsAcceptReq => auth::handle_accept_req(stream, packet).await,
PacketType::PakcsJoinServerTokenReq => auth::handle_join_server_req(stream, packet, self.auth_client.clone(), self.connection_service.clone(), connection_id).await,
// Login Packets