mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-07 05:35:41 +12:00
fix logout
This commit is contained in:
parent
feb974de09
commit
03c2b8e5a1
2 changed files with 3 additions and 2 deletions
|
@ -25,8 +25,6 @@ namespace HISP.Server
|
|||
return false;
|
||||
if (LoggedinUser.LoggedinClient == null)
|
||||
return false;
|
||||
if (isDisconnecting)
|
||||
return false;
|
||||
return login;
|
||||
}
|
||||
set
|
||||
|
|
|
@ -7270,8 +7270,10 @@ namespace HISP.Server
|
|||
|
||||
public static void OnDisconnect(GameClient sender)
|
||||
{
|
||||
|
||||
connectedClients.Remove(sender);
|
||||
|
||||
|
||||
if (sender.LoggedIn)
|
||||
{
|
||||
Database.SetPlayerLastLogin(Convert.ToInt32(new DateTimeOffset(DateTime.UtcNow).ToUnixTimeSeconds()), sender.LoggedinUser.Id); // Set last login date
|
||||
|
@ -7320,6 +7322,7 @@ namespace HISP.Server
|
|||
client.SendPacket(playerRemovePacket);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Add table
Reference in a new issue