friendAdd and friendRemove update PlayerObject FriendList now

This commit is contained in:
Waverunner
2013-12-10 18:53:42 -05:00
parent 5f616ed5f0
commit 1065c70c55
4 changed files with 22 additions and 19 deletions
@@ -417,6 +417,7 @@ public class PlayerObject extends SWGObject {
public void friendAdd(String friend) {
synchronized(objectMutex) {
setFriendListUpdateCounter(getFriendListUpdateCounter() + 1);
friendList.add(friend);
getContainer().getClient().getSession().write(messageBuilder.buildFriendAddDelta(friend));
}
}
@@ -424,6 +425,7 @@ public class PlayerObject extends SWGObject {
public void friendRemove(String friend) {
synchronized(objectMutex) {
setFriendListUpdateCounter(getFriendListUpdateCounter() + 1);
friendList.remove(friend);
getContainer().getClient().getSession().write(messageBuilder.buildFriendRemoveDelta(friend));
}
}