To complete the integration of achievements and leaderboards, we are going to add buttons to open the native UI provided by GPGS to our main menu.
For this, we are going to place two buttons in the bottom–left corner of the screen, opposite the music and sound buttons. We will also check whether we are connected or not; if not, we will show a single sign-in button.
For these buttons we will use the official images of GPGS, which are available for developers to use. Note that you must follow the brand guidelines while using the icons and they must be displayed as they are and not modified. This also provides a consistent look and feel across all the games that support Play Games.
Since we have seen a lot of layouts already, we are not going to include another one that is almost the same as something we already have.
To handle these new buttons we will, as usual, set the MainMenuFragment
as OnClickListener...