playgameservices / play-games-plugin-for-unity

Google Play Games plugin for Unity
Other
3.45k stars 963 forks source link

CRASH: Application crashing when returning from ShowSelectSavedGameUI #3207

Closed frankvHoof93 closed 1 year ago

frankvHoof93 commented 1 year ago

Describe the bug

When the Application returns from the ShowSelectSavedGameUI-overlay, the Application crashes. This happens both when a SavedGame has been selected as well as when the user hits 'Back' (not selecting a save).

To Reproduce Steps to reproduce the behavior:

  1. Open Application, Authenticate, etc.
  2. Call PlayGamesPlatform.Instance.SavedGame.ShowSelectSavedGameUI() (as described in the "Displaying saved games UI"-section)
  3. Select a Saved Game, or click the Back-Button on the device
  4. App Crashes

Expected behavior The callback assigned to the ShowSelectSavedGame-invocation is triggered with the Status & MetaData

Observed behavior The entire Application Crashes

Bug Report CrashLog_ADB.txt

Versions

smile616 commented 1 year ago

@frankvHoof93

Seems like the problem is not related to Google Play Games Plugin for Unity:

They the following:

  1. In the application permission settings give access the ReadPhoneState (or the best fit) to the game
  2. Disable/remove com.oplus.statistics code at least temporarily

One of those or both will likely fix the issue.

frankvHoof93 commented 1 year ago

com.oplus.statistics is a back-end OS-process (Oppo ColorOS), and not related to my application. I believe this is related to Oppo's own 'Google Play Games'-app, but I'm not 100% sure on that.

I tried adding the ReadPhoneState-permission, with no result. However, it appears that this bug is not (necessarily) related to the Google Play Games Plugin, but to Unity itself. Thus, this issue can (remain) closed.

Explanation for others below: Apparently the "ReadPhoneState" is related to FMod and Bluetooth. Unity Issue Tracker: https://issuetracker.unity3d.com/issues/android-player-crashing-in-fmod-when-targetting-sdk-level-31

Disabling Bluetooth causes the Application to not crash (on this specific version of Unity, 2021.3.6f1).

Edit: I can now confirm that switching to Unity 2021.3.9f1 also resolves this issue.

smile616 commented 1 year ago

@frankvHoof93, thank you for the update!