Page 1 of 1

BuddyID & PlayerID relationship information

Posted: 14 Jul 2011, 10:36
by whornak
When checking to see if an existing player is on another buddylist I check BuddyID against PlayerID when looping through the buddylist.

This seems to work fine and am not sure how I came to that conclusion but would like confirmation on its accuracy. Also, if possible, could some information about the management of the ID's be provided so that I can better understand the relationship.

Posted: 14 Jul 2011, 14:12
by Bax
PlayerID and BuddyID are not related at all.

Posted: 14 Jul 2011, 15:28
by whornak
So what would be the process to determine if a existing player is a buddy or not so that certain buddy related interations can be performed?

Posted: 15 Jul 2011, 09:32
by Bax
You have to use the User.id property, and check if the user is also a buddy using the SmartFox.buddyManager.getBuddyById method.