question

Damian Rajamanie avatar image
Damian Rajamanie asked

Oculus friends Support

It would seem that Oculus friends arenot supported like the other platforms (there seems to be Facebook, twitch, Nintendo etc.)

I can retrieve the Oculus List of friends from their SDK, but is there a playfab workaround to match them up with Playfab IDs, such as the:

GetPlayFabIDsFromPSNAccountIDs

call?

GetPlayFabIDsFromGenericIDs (https://api.playfab.com/documentation/client/method/GetPlayFabIDsFromGenericIDs)

I'm wondering about the best approach here. Our game is cross platform, currently impleemented with Steam Friends, and we should be able to soon add PSN based on our other login and account resolution I posted above)

My initial thoughts would be:

I have an Oculus SKU build, so for those users running that build:

1) When they log in, call AddGenericID using "Oculus" and an OculusUniqueID

2) When retreiving friends, get a list of OculusUniqueID from the Oculus SDK and use GetPlayFabIDsFromPSNAccountIDs providing "Oculus" for everyone in that list.

3) Do this multiple times is there are more than 10 people in the Oculus Frind list.

Will this return to me a list back of reconciled Playfab account? nulls for those friends who aren't PlayFab registered (i.e. people who have never run the AddGenericID).

This seems like it would be your workaround for platforms that are not aupported, but I'm not 100% I also worry about the whole friends unfriending each other etc. as I will need to somehow deal with all of that - includeSteam: true for Steam friends takes care of all that.

Cheers

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

brendan avatar image
brendan answered

We currently provide integration with Facebook and Steam friends, and provide our own friends list service. It's possible we'll add support for Oculus friends in future, but we don't have any specific plans for that right now. You could potentially store the friends in each others' PlayFab friends list, if that won't violate any policies on Oculus. But I cannot recommend trying any process that requires you to iteratively calls API endpoints to collect information about users, as that could rapidly run you up against rate limits, causing throttling on your title (a friends list could contain thousands of people in any modern friends system).

2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Damian Rajamanie avatar image Damian Rajamanie commented ·

"You could potentially store the friends in each others' PlayFab friends list" How would I reconcile the Oculus IDs I get from the Oculus SDK with the Playfab IDs associated with them?

Thus far all I can see is that I could get some Oculus ID, but I have no way of telling if that person has created a PlayFab account.

0 Likes 0 ·
brendan avatar image brendan Damian Rajamanie commented ·

One way would be to store the Oculus IDs as Generic IDs in our service, though that would only allow you to look up one player at a time.

0 Likes 0 ·
Damian Rajamanie avatar image
Damian Rajamanie answered

Ok I'm implementing it the way I outlined and I would just like to confirm something I'm alittle worried about:

1) Upon logging in (Every session) I add the generic Id with "Oculus" as the Servicname and the users OculusID thus:

PlayFabClientAPI.AddGenericID(request, _onAddGenericIDSuccess, _onAddGenericIDFailure);

2) On the first attempt _onAddGenericIDSuccess() is called - this is a good sign, but there's currently no way for me to see who or what my ServiceOIds vs Users are, so I go on Faith and assume there is ONE entry somewhere that is not exposed to me

3) On subsequent logins and calls, I still get: _onAddGenericIDSuccess() - I would expect it to fail with error 1238 - IdentifierAlreadyClaimed as I already did it.

So I'm a little worried about 3), are multiple entries being added somewhere? could this come back to bite me by having 10000s of Service IDs and users? am I misreading this and it's all gravy and supposed to return success, EVEN though it has already been added?

As long as 3 is all good, I will then collect 10 at a time Service Ids for the Oculus friends in order to get thier PF ids and then add them as friends. The calls won't be 10000s, as the Oculus SDK supposedly only returns friends who actually own the game anyway, and using the friends list as a cache, I will only be retrieving 'new' people after the initial Import

1 comment
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

brendan avatar image brendan commented ·

If you call AddGenericID with an ID (service/ID) that is already on the user, the service simply returns OK, as the player does have that ID. Nothing new is added to the player account. I'd encourage making sure that the code cannot make excessive calls to get friend info even in your worst case (I join a game that hundreds of my players are already playing), as that could cause issues for your title.

1 Like 1 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.