BuddyID & PlayerID relationship information

Post here your questions about the Flash / Flex / Air API for SFS2X

Moderators: Lapo, Bax

Post Reply
whornak
Posts: 86
Joined: 22 Sep 2009, 11:05

BuddyID & PlayerID relationship information

Post 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.
User avatar
Bax
Site Admin
Posts: 4626
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Post by Bax »

PlayerID and BuddyID are not related at all.
Paolo Bax
The SmartFoxServer Team
whornak
Posts: 86
Joined: 22 Sep 2009, 11:05

Post 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?
User avatar
Bax
Site Admin
Posts: 4626
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Post 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.
Paolo Bax
The SmartFoxServer Team
Post Reply