diff --git a/AscNet.GameServer/Handlers/AccountModule.cs b/AscNet.GameServer/Handlers/AccountModule.cs index 3347268..5b6b0f6 100644 --- a/AscNet.GameServer/Handlers/AccountModule.cs +++ b/AscNet.GameServer/Handlers/AccountModule.cs @@ -45,6 +45,7 @@ namespace AscNet.GameServer.Handlers [RequestPacketHandler("LoginRequest")] public static void LoginRequestHandler(Session session, Packet.Request packet) { + start: LoginRequest request = MessagePackSerializer.Deserialize(packet.Content); Player? player = Player.FromToken(request.Token); @@ -63,6 +64,9 @@ namespace AscNet.GameServer.Handlers // GateServerForceLogoutByAnotherLogin previousSession.SendPush(new ForceLogoutNotify() { Code = 1018 }); previousSession.DisconnectProtocol(); + + // Player data will be outdated without refetching it after disconnecting the previous session. + goto start; } session.player = player;