Skip to content
10 changes: 9 additions & 1 deletion GuildWarsInterface/Datastructures/Components/FriendList.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,14 @@ public void Add(Type type, string baseCharacterName, string currentCharacterName
{
var newEntry = new Entry(type, baseCharacterName, currentCharacterName, playerStatus, map);

_entries.Add(newEntry.BaseCharacterName, newEntry);
if (!_entries.ContainsKey(newEntry.BaseCharacterName))
{
_entries.Add(newEntry.BaseCharacterName, newEntry);
}
else
{
_entries[newEntry.BaseCharacterName] = newEntry;
}

if (Game.State == GameState.Playing)
{
Expand Down Expand Up @@ -82,6 +89,7 @@ private static void UpdateEntry(Entry entry)
{
Network.AuthServer.Send(AuthServerMessage.UpdateFriendList, (uint) entry.PlayerStatus, entry.BaseCharacterName, entry.CurrentCharacterName);

//If a map was specified, show it next to name
if (entry.Map != 0)
{
Network.AuthServer.Send(AuthServerMessage.FriendListLocationInfo, (uint) entry.Map,
Expand Down
2 changes: 1 addition & 1 deletion GuildWarsInterface/Networking/Network.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ public static void Initialize()
GameServer.Start();
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ internal enum AuthServerMessage
FriendListLocationInfo = 32,
Response53 = 38,
}
}
}
6 changes: 3 additions & 3 deletions GuildWarsInterface/Networking/Servers/FileServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ protected override void Received(byte[] data)
Send(new byte[]
{
0xF1, 0x02, 0x20, 0x00, 0x6F, 0xC0, 0x05, 0x00,
0x7E, 0xC9, 0x05, 0x00, 0x9C, 0x43, 0x05, 0x00,
0x8C, 0xC9, 0x05, 0x00, 0x8D, 0xC9, 0x05, 0x00,
0x8E, 0xC9, 0x05, 0x00, 0x8B, 0xC9, 0x05, 0x00
0xB3, 0xC9, 0x05, 0x00, 0x9C, 0x43, 0x05, 0x00,
0xB5, 0xC9, 0x05, 0x00, 0xB6, 0xC9, 0x05, 0x00,
0xB7, 0xC9, 0x05, 0x00, 0xB4, 0xC9, 0x05, 0x00
});
}
}
Expand Down