mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-07 13:45:42 +12:00
fix mail count
This commit is contained in:
parent
e5fa0caccd
commit
6ff3d91135
2 changed files with 6 additions and 3 deletions
|
@ -23,8 +23,12 @@ namespace HISP.Player
|
|||
{
|
||||
int i = 0;
|
||||
foreach (Mail mail in MailMessages)
|
||||
{
|
||||
if (!mail.Read)
|
||||
{
|
||||
i++;
|
||||
}
|
||||
}
|
||||
return i;
|
||||
}
|
||||
}
|
||||
|
@ -82,8 +86,7 @@ namespace HISP.Player
|
|||
mails[i].Read = true;
|
||||
}
|
||||
|
||||
byte[] BaseStatsPacketData = PacketBuilder.CreatePlayerData(baseUser.Money, GameServer.GetNumberOfPlayers(), this.UnreadMailCount);
|
||||
baseUser.LoggedinClient.SendPacket(BaseStatsPacketData);
|
||||
GameServer.UpdatePlayer(baseUser.LoggedinClient);
|
||||
}
|
||||
public void AddMail(Mail mailMessage)
|
||||
{
|
||||
|
|
|
@ -7535,7 +7535,7 @@ namespace HISP.Server
|
|||
Logger.ErrorPrint(forClient.RemoteIp + "tried to update player information when not logged in.");
|
||||
return;
|
||||
}
|
||||
byte[] PlayerData = PacketBuilder.CreatePlayerData(forClient.LoggedinUser.Money, GameServer.GetNumberOfPlayers(), forClient.LoggedinUser.MailBox.MailCount);
|
||||
byte[] PlayerData = PacketBuilder.CreatePlayerData(forClient.LoggedinUser.Money, GameServer.GetNumberOfPlayers(), forClient.LoggedinUser.MailBox.UnreadMailCount);
|
||||
forClient.SendPacket(PlayerData);
|
||||
}
|
||||
public static void UpdateUserFacingAndLocation(User user)
|
||||
|
|
Loading…
Add table
Reference in a new issue