Hi,
I need help on the logic of a custom friends list, I don't understand when it is better to update the various states of the user, it is better:
1) Send your change of status to your entire friends list (Online, Offline, InGame, ExitClan, EnterClan, ChangeUsername)
2) Send the user an update of all friends every 60 seconds
3) Send the user an update of the list every time he opens the friends list, but when the state changed the user could have the friends list open, so he would continue to see the previous state
Updating the friends list
Re: Updating the friends list
Hi,
why not using the existing BuddyList API?
those states are already handled by the Buddy List API, for you, so you don't have to implement any special logic.
Have you checked the documentation?
http://docs2x.smartfoxserver.com/Advanc ... y-list-api
Also you can find practical examples of how to use the BuddyList API in almost all supported platforms:
https://www.smartfoxserver.com/download#p=examples
Cheers
why not using the existing BuddyList API?
those states are already handled by the Buddy List API, for you, so you don't have to implement any special logic.
Have you checked the documentation?
http://docs2x.smartfoxserver.com/Advanc ... y-list-api
Also you can find practical examples of how to use the BuddyList API in almost all supported platforms:
https://www.smartfoxserver.com/download#p=examples
Cheers
Re: Updating the friends list
Hi,
I like to have control of everything on my server, can you please help me with the logic?
I like to have control of everything on my server, can you please help me with the logic?
Re: Updating the friends list
1) Send your change of status to your entire friends list (Online, Offline, InGame, ExitClan, EnterClan, ChangeUsername)
Sounds like the normal solution. When a user changes its state you need to update all the other clients that have this User in their list.
2) Send the user an update of all friends every 60 seconds
This can be more expensive if the state of a certain amount of friends did not change and it's also very delayed as you don't get a real-time update.
3) Send the user an update of the list every time he opens the friends list, but when the state changed the user could have the friends list open, so he would continue to see the previous state
Doesn't sound like a good strategy.
Cheers
Re: Updating the friends list
Thank you
Who is online
Users browsing this forum: No registered users and 64 guests