If your game with Hive SDK v4 is unable to use Firebase Analytics, follow the below to resolve the issue.
- Change the metadata on the AndroidManifest.xml file.
| <application> <meta-data android:name="firebase_analytics_collection_deactivated" tools:node="remove" /> <meta-data android:name="firebase_analytics_collection_enabled" android:value="false" /> |
- Activate the Firebase Analytics after completing the initialization of Hive SDK.
| // Request to initialize Hive SDK v4 AuthV4.setup (delegate ( ResultAPI result, Boolean isAutoSignIn, String did, List<AuthV4.ProviderType> providerTypeList) { if (result.code == ResultAPI.Code.Success) { // Success in the initialization if (Configuration.getAgeGateU13() == false) { // Activate the Firebase Analytics with users age 13 and above setAnalyticsCollectionEnabled(true); } else { // Inactivate the Firebase Analytics with users under 13 setAnalyticsCollectionEnabled(false); } } }); |
|