Google Play Games 2017: How do I invite someone to a multiplayer match?

Google announced in December 2016 that Google+ was no longer integrated into Google Play Games services: https://android-developers.googleblog.com/2016/12/games-authentication-adopting-google.html And, as a result, a method call Unities Social.localUser.LoadFriends()returns zero friends. Now that you have no friends, how do you invite other players to a multiplayer match with Googles Play Games Services?

+4
source share
1 answer

The Google Play Game Services documentation has a sample code on how to invite G + friends and anonymous players at this link: https://developers.google.com/games/services/android/realtimeMultiplayer#invite_players_option , btw is an outdated example and not Reflects the actual API changes.

August 2017 update

Currently, RealTimeMultiplayer.getSelectOpponentsIntent(...)many other methods are marked as obsolete in the documents. (They were not when the answer was given). Read here for more info on this.

0
source

Source: https://habr.com/ru/post/1678095/


All Articles