Search Unity

[Released] Android Native Plugin

Discussion in 'Assets and Asset Store' started by lacost, Sep 20, 2013.

  1. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    This is quite common issue if you have a lot of 3rd party plugins with Google Play Services libs included.
    To avoid time wasting, I would recommend you to contact our support team and ask for an assistance.
    Please, go ahead, you will get great support in a short time!
     
  2. BenoitFreslon

    BenoitFreslon

    Joined:
    Jan 16, 2013
    Posts:
    131
    Hello I tested the last Android Native plugin with Unity 2017.1

    But My app name is changed to AN_Billing

    EDIT 2: FIXED! I used non stable version of Unity 2017.1

    EDIT: if I remove the "Billing lib" in the "Android Native Settings" the app name changes to "AN_GooglePlay"

    Probably because there is config file with the app_name: AN_Billling in values.xml

    <string name="app_name">AN_Billing</string

    Code (JavaScript):
    1. <?xml version="1.0" encoding="utf-8"?>
    2. <resources>
    3.     <dimen name="activity_horizontal_margin">16dp</dimen>
    4.     <dimen name="activity_vertical_margin">16dp</dimen>
    5.     <string name="action_settings">Settings</string>
    6.     <string name="app_name">AN_Billing</string>
    7.     <string name="hello_world">Hello world!</string>
    8.     <style name="AppBaseTheme" parent="android:Theme.Light">
    9.         <!--
    10.             Theme customizations available in newer API levels can go in
    11.             res/values-vXX/styles.xml, while customizations related to
    12.             backward-compatibility can go here.
    13.         -->
    14.     </style>
    15.     <style name="AppTheme" parent="AppBaseTheme">
    16.         <!-- All customizations that are NOT specific to a particular API-level can go here. -->
    17.     </style>
    18. </resources>
     
    Last edited: Aug 14, 2017
  3. Ryoha

    Ryoha

    Joined:
    Mar 5, 2017
    Posts:
    7
    Hello Again...
    I've sent email to support team, and 2 days later they reply with solution.
    Now I can use them both plugin, that amazing!
    Thank you. Problem Solved!
     
  4. mabourdages

    mabourdages

    Joined:
    Oct 4, 2016
    Posts:
    1
    I have the same issue, mind telling us the solution?
     
  5. Ryoha

    Ryoha

    Joined:
    Mar 5, 2017
    Posts:
    7
    Sure, glad I can share. First install AN-plugin.
    Then import and do this steps:
    1) Open AndroidManifest.xml by path: Plugins -> Android, add this field
    xmlns:tools="http://schemas.android.com/tools"
    to tag <Manifest

    2) Then add this parameter
    tools:replace="android:icon"
    to tag <Application

    3) Finally open AndroidManifest.xml by path: Plugins -> Android -> AN_Res and remove android:icon="@drawable/app_icon" android:label="@String/app_name" from tag <application

    4) Replace old aar files with this one: https://mega.nz/#F!3oUUwQrY!p3LP60JvwrO_ya02iVkATA

    Then Import Appodeal.

    5) Open AndroidManifest.xml in Plugins -> Android and cut this
    android:debuggable="true" from tag <Application

    6) Then removed:
    • play-services-ads.aar
    • play-services-ads-lite.aar
    • play-services-safetynet.aar
    • play-services-tasks.aar
    • play-services-basement.aar
    • play-services-base.aar
    • play-services-games.aar
    • play-services-plus.aar
    • support-v4-24.1.1.aar
    • inmobi-ads-6.2.0.jar
    • chartboost-6.6.1.jar
    • facebook-audience-network-4.22.0.jar
     
    AlexRay likes this.
  6. CasperIsFriendly

    CasperIsFriendly

    Joined:
    Aug 8, 2017
    Posts:
    1
    Ryoha, thanks for sharing the solution!

    mabourdages, let us know if you're still facing any issues and I'd be glad to assist.
     
  7. BenoitFreslon

    BenoitFreslon

    Joined:
    Jan 16, 2013
    Posts:
    131
    Last edited: Aug 16, 2017
  8. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello!
    With the latest update, we released the Firebase Dynamic Links.
    Maybe that's the right feature you are looking for or even better.
    Please, check the official documentation and if you will have any kind of additional questions, feel free to contact our support team. You are welcome!
     
  9. marquesbelem

    marquesbelem

    Joined:
    Oct 28, 2016
    Posts:
    1
    About google play games RTM:

    Would you like to know what you do in this part of the code? Full name OnGCDataReceived

    GP_Partisipant p = GooglePlayRTM.Instance.currentRoom.GetPartisipantById(package.participantId);
    if(p != null) {
    GooglePlayerTemplate player = GooglePlayManager.Instance.GetPlayerById(p.PlayerId);
    if(player != null) {
    name = player.Name; } }
     
  10. Webbstre

    Webbstre

    Joined:
    Mar 7, 2015
    Posts:
    35
    I'm having trouble figuring out to disable the request for Location Services. I'm not even sure what is using them. Any suggestions? The ACCESS_FINE_LOCATION doesn't appear to exist anymore.
     
  11. corvuspink

    corvuspink

    Joined:
    Aug 28, 2017
    Posts:
    1
    (There may be awkward sentences using Google Translator.)
    Good morning! I'm going to die because of this problem.
    After installing the plugin, I can not build it, and it seems that the code is more twisted as I try to find a solution like this and try it out.

    There are currently three error messages,


    C:\Users\user\OneDrive\01. GameDevelop\01. UnityProject\Release\GulHap\Temp\StagingArea\AndroidManifest-main.xml:6:16-49 Error:
    Attribute application@icon value=(@drawable/app_icon) from AndroidManifest-main.xml:6:16-49
    is also present at AndroidManifest.xml:13:9-45 value=(@drawable/ic_launcher).
    Suggestion: add 'tools:replace="android:icon"' to <application> element at AndroidManifest-main.xml:6:3-47:17 to override.

    UnityEditor.HostView:OnGUI()



    //////


    AndroidSDKToolsException: Unable to merge android manifests. See the Console for more details.
    UnityEditor.Android.AndroidSDKTools.DetectErrorsAndWarnings (System.String logMessages, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.RunCommandInternal (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.RunCommandSafe (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.RunCommand (System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.RunCommand (System.String[] sdkToolCommand, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.RunCommand (System.String[] sdkToolCommand, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.MergeManifests (System.String target, System.String mainManifest, System.String[] libraryManifests, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit)
    UnityEditor.Android.PostProcessor.Tasks.GenerateManifest.MergeManifests (UnityEditor.Android.PostProcessor.PostProcessorContext context, System.String targetManifest, System.String mainManifest)
    UnityEditor.Android.PostProcessor.Tasks.GenerateManifest.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context)
    UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context)
    UnityEditor.HostView:OnGUI()


    //////

    UnityEditor.BuildPlayerWindow+BuildMethodException: Build failed with errors.
    at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (BuildPlayerOptions options) [0x001b9] in C:\buildslave\unity\build\Editor\Mono\BuildPlayerWindowBuildMethods.cs:162
    at UnityEditor.BuildPlayerWindow.CallBuildMethods (Boolean askForBuildLocation, BuildOptions defaultBuildOptions) [0x00050] in C:\buildslave\unity\build\Editor\Mono\BuildPlayerWindowBuildMethods.cs:83
    UnityEditor.HostView:OnGUI()



    Why does not it build? Thank you.(I can read English!!)
    Thank you.
     
    lost9725 likes this.
  12. Emptiness

    Emptiness

    Joined:
    Jul 14, 2012
    Posts:
    33
    Hi :)
    I've just installed the latest Android Native Plugin Into a clean project and an empty screen and I get build errors. (Unity 2017.1)
    Is this asset ready to use with Unity 2017?
    I'd like to use only the gallery function and switching off the rest of the features gives the same error as well.
    Thanks for any help.

    build errors:

    CommandInvokationFailure: Failed to re-package resources.
    C:\MISC\AndroidSDK\build-tools\25.0.2\aapt.exe package --auto-add-overlay -v -f -m -J "gen" -M "AndroidManifest.xml" -S "res" -I "C:/MISC/AndroidSDK\platforms\android-25\android.jar" -F bin/resources.ap_ --extra-packages com.example.androidnative:com.stansassets.androidnative:com.google.android.gms.appinvite:com.google.android.gms.auth.api:com.google.android.gms.auth:com.google.android.gms.plus:android.support.v4 -S "H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res" -S "H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\AN_Res\res" -S "H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-appinvite\res" -S "H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth\res" -S "H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth-base\res" -S "H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res" -S "H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\support-v4-24.1.1\res"

    stderr[
    H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth\res\drawable-watch-v20\common_google_signin_btn_text_dark_normal.xml:9: error: Error: No resource found that matches the given name (at 'src' with value '@drawable/googleg_standard_color_18').

    H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth\res\drawable-watch-v20\common_google_signin_btn_text_disabled.xml:16: error: Error: No resource found that matches the given name (at 'src' with value '@drawable/googleg_disabled_color_18').

    H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth\res\drawable-watch-v20\common_google_signin_btn_text_light_normal.xml:9: error: Error: No resource found that matches the given name (at 'src' with value '@drawable/googleg_standard_color_18').

    ]
    stdout[
    Configurations:
    (default)

    Files:
    AndroidManifest.xml
    Src: () AndroidManifest.xml

    Resource Dirs:
    Including resources from package: C:\MISC\AndroidSDK\platforms\android-25\android.jar
    applyFileOverlay for drawable
    trying overlaySet Key=ic_plusone_medium_off_client.png
    trying overlaySet Key=ic_plusone_small_off_client.png
    trying overlaySet Key=ic_plusone_standard_off_client.png
    trying overlaySet Key=ic_plusone_tall_off_client.png
    trying overlaySet Key=common_google_signin_btn_text_dark_normal.xml
    trying overlaySet Key=common_google_signin_btn_text_disabled.xml
    trying overlaySet Key=common_google_signin_btn_text_light_normal.xml
    trying overlaySet Key=ic_launcher.png
    trying overlaySet Key=app_banner.png
    trying overlaySet Key=app_icon.png
    applyFileOverlay for layout
    trying overlaySet Key=activity_main.xml
    applyFileOverlay for anim
    applyFileOverlay for animator
    applyFileOverlay for interpolator
    applyFileOverlay for transition
    applyFileOverlay for xml
    trying overlaySet Key=file_paths.xml
    applyFileOverlay for raw
    applyFileOverlay for color
    applyFileOverlay for menu
    trying overlaySet Key=main.xml
    applyFileOverlay for mipmap
    Processing image: res\drawable-xhdpi\app_banner.png
    Processing image: res\drawable-mdpi\app_icon.png
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-mdpi-v4\ic_launcher.png
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-hdpi-v4\ic_launcher.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-mdpi-v4\ic_launcher.png: 82% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-xhdpi-v4\ic_launcher.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-hdpi-v4\ic_launcher.png: 77% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-xxhdpi-v4\ic_launcher.png
    (processed image res\drawable-mdpi\app_icon.png: 90% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_medium_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_medium_off_client.png: 103% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_medium_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_medium_off_client.png: 103% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_medium_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_medium_off_client.png: 103% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_medium_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_medium_off_client.png: 99% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_medium_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-xhdpi-v4\ic_launcher.png: 74% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_small_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_small_off_client.png: 102% size of source)
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_medium_off_client.png: 102% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_small_off_client.png
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_small_off_client.png
    (processed image res\drawable-xhdpi\app_banner.png: 93% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_small_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_small_off_client.png: 95% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_small_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_small_off_client.png: 100% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_standard_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_small_off_client.png: 102% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_standard_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_standard_off_client.png: 102% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_standard_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_small_off_client.png: 108% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_standard_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_standard_off_client.png: 104% size of source)
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_standard_off_client.png: 104% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_standard_off_client.png
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_tall_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-mdpi-v4\ic_plusone_tall_off_client.png: 102% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_tall_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_standard_off_client.png: 100% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_tall_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-tvdpi-v4\ic_plusone_tall_off_client.png: 103% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_tall_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-hdpi-v4\ic_plusone_tall_off_client.png: 104% size of source)
    Processing image: H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_tall_off_client.png
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xhdpi-v4\ic_plusone_tall_off_client.png: 100% size of source)
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_standard_off_client.png: 100% size of source)
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-plus\res\drawable-xxhdpi-v4\ic_plusone_tall_off_client.png: 107% size of source)
    (processed image H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\androidnative\res\drawable-xxhdpi-v4\ic_launcher.png: 72% size of source)
    (new resource id app_banner from xhdpi-v4\drawable\app_banner.png #generated)
    (new resource id app_icon from mdpi-v4\drawable\app_icon.png #generated)
    (new resource id common_google_signin_btn_text_dark_normal from H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth\res\drawable-watch-v20\common_google_signin_btn_text_dark_normal.xml)
    (new resource id common_google_signin_btn_text_disabled from H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth\res\drawable-watch-v20\common_google_signin_btn_text_disabled.xml)
    (new resource id common_google_signin_btn_text_light_normal from H:\Unity_TESTS\AndroidNativePlugin3\AndroidNP_image2017\Temp\StagingArea\android-libraries\play-services-auth\res\drawable-watch-v20\common_google_signin_btn_text_light_normal.xml)
    (new resource id ic_launcher from mdpi-v4\drawable\ic_launcher.png #generated)
    (new resource id ic_launcher from hdpi-v4\drawable\ic_launcher.png #generated)
    (new resource id ic_launcher from xhdpi-v4\drawable\ic_launcher.png #generated)
    (new resource id ic_launcher from xxhdpi-v4\drawable\ic_launcher.png #generated)
    (new resource id ic_plusone_medium_off_client from mdpi-v4\drawable\ic_plusone_medium_off_client.png #generated)
    (new resource id ic_plusone_medium_off_client from tvdpi-v4\drawable\ic_plusone_medium_off_client.png #generated)
    (new resource id ic_plusone_medium_off_client from hdpi-v4\drawable\ic_plusone_medium_off_client.png #generated)
    (new resource id ic_plusone_medium_off_client from xhdpi-v4\drawable\ic_plusone_medium_off_client.png #generated)
    (new resource id ic_plusone_medium_off_client from xxhdpi-v4\drawable\ic_plusone_medium_off_client.png #generated)
    (new resource id ic_plusone_small_off_client from mdpi-v4\drawable\ic_plusone_small_off_client.png #generated)
    (new resource id ic_plusone_small_off_client from tvdpi-v4\drawable\ic_plusone_small_off_client.png #generated)
    (new resource id ic_plusone_small_off_client from hdpi-v4\drawable\ic_plusone_small_off_client.png #generated)
    (new resource id ic_plusone_small_off_client from xhdpi-v4\drawable\ic_plusone_small_off_client.png #generated)
    (new resource id ic_plusone_small_off_client from xxhdpi-v4\drawable\ic_plusone_small_off_client.png #generated)
    (new resource id ic_plusone_standard_off_client from mdpi-v4\drawable\ic_plusone_standard_off_client.png #generated)
    (new resource id ic_plusone_standard_off_client from tvdpi-v4\drawable\ic_plusone_standard_off_client.png #generated)
    (new resource id ic_plusone_standard_off_client from hdpi-v4\drawable\ic_plusone_standard_off_client.png #generated)
    (new resource id ic_plusone_standard_off_client from xhdpi-v4\drawable\ic_plusone_standard_off_client.png #generated)
    (new resource id ic_plusone_standard_off_client from xxhdpi-v4\drawable\ic_plusone_standard_off_client.png #generated)
    (new resource id ic_plusone_tall_off_client from mdpi-v4\drawable\ic_plusone_tall_off_client.png #generated)
    (new resource id ic_plusone_tall_off_client from tvdpi-v4\drawable\ic_plusone_tall_off_client.png #generated)
    (new resource id ic_plusone_tall_off_client from hdpi-v4\drawable\ic_plusone_tall_off_client.png #generated)
    (new resource id ic_plusone_tall_off_client from xhdpi-v4\drawable\ic_plusone_tall_off_client.png #generated)
    (new resource id ic_plusone_<message truncated>
     
  13. SoftwareGeezers

    SoftwareGeezers

    Joined:
    Jun 22, 2013
    Posts:
    505
    I believe I've just identified a crippling bug where failing to disconnect before closing an app causes it to never to be able to connect again.
    (Using Unity 5.6.1)

    I'm getting completely inconsistent results trying to log onto Google Play Services. It appears to only ever work once.

    My game does not connect, returning error code 4, with accountname = null.

    I created a blank project and imported Android Native 9.7, the version my game is using. I created a new Google App and used the same signing key as my game. I built the app and signed it with my game's key linking to this dummy App and it worked. I then linked it to my game app (changed package name, using same signing key) and it wouldn't connect, giving an error code 4. I then reverted to the dummy app package name and it wouldn't connect.

    I created a new app using Android Native 9.8. I built it using the same settings and it wouldn't connect. I cleared the Google Apps data and it wouldn't connect.

    I then ran this app on my phone instead of tablet and it connected just fine. I then closed the app and ran it again and I can no longer connect. I've tried clearing data and it won't connect, always giving error code 4.

    09-01 19:52:03.796: D/AndroidNative(25779): IsPlayServiceAlavliable ConnectionResult:0
    09-01 19:52:03.796: D/AndroidNative(25779): GP::sighIn accountName:null
    09-01 19:52:03.912: D/AndroidNative(25779): GooglePlaySupportActivity::eek:nStart
    09-01 19:52:03.912: D/AndroidNative(25779): GooglePlaySupportActivity onStart typeCode:GOOGLE_PLAY_CONNECTION
    09-01 19:52:03.912: D/AndroidNative(25779): GP::StartSignRequest accountName:null
    09-01 19:52:03.919: D/AndroidNative(25779): Google Play sighIn started
    09-01 19:52:04.272: D/AndroidNative(25779): *************************************************************
    09-01 19:52:04.272: D/AndroidNative(25779): *************************************************************
    09-01 19:52:04.272: D/AndroidNative(25779): *************** GOOGLE PLAY CONNECTION FAILED ***************
    09-01 19:52:04.272: D/AndroidNative(25779): ERROR CODE: 4 ***************
    09-01 19:52:04.272: D/AndroidNative(25779): HAS RESOLUTION: true ***************
    09-01 19:52:04.272: D/AndroidNative(25779): DESCRIBTION: SIGN_IN_REQUIRED - The client attempted to connect to the service but the user is not signed in. The client may choose to continue without using the API or it may call startResolutionForResult(Activity, int) to prompt the user to sign in. After the sign in activity returns with RESULT_OK further attempts to connect should succeed.
    09-01 19:52:04.272: D/AndroidNative(25779): READ MORE: http://developer.android.com/reference/com/google/android/gms/common/ConnectionResult.html
    09-01 19:52:04.272: D/AndroidNative(25779): *************************************************************
    09-01 19:52:04.275: D/AndroidNative(25779): *************************************************************
    09-01 19:52:04.389: D/AndroidNative(25779): Skipping Reconnection on start
    09-01 19:52:04.425: D/AndroidNative(25779): GooglePlaySupportActivity::eek:nStop
    09-01 19:52:04.425: D/AndroidNative(25779): Submiting result on activity stop
    09-01 19:52:04.425: D/AndroidNative(25779): GCM::eek:nActivityResult request 0 response 0 data null
    09-01 19:52:05.340: D/AndroidNative(25779): GooglePlaySupportActivity::eek:nStart
    09-01 19:52:10.998: D/AndroidNative(25779): GooglePlaySupportActivity::eek:nActivityResult
    09-01 19:52:10.998: D/AndroidNative(25779): GCM::eek:nActivityResultDiconnectCheck
    09-01 19:52:10.998: D/AndroidNative(25779): GamesActivityResultCodes response 10002
    09-01 19:52:11.002: D/AndroidNative(25779): GCM::eek:nActivityResult request 9001 response 10002 data Intent { (has extras) }
    09-01 19:52:11.008: D/AndroidNative(25779): result: REQUEST_CODE_RESOLUTION resultCode:10002 Intent data: Intent { (has extras) }
    09-01 19:52:11.008: D/AndroidNative(25779): onSignInFailed with code: 10002
    09-01 19:52:11.008: D/AndroidNative(25779): ************** FINAL: Google Play Connection result: 10002 ************
    09-01 19:52:11.226: D/AndroidNative(25779): Skipping Reconnection on start
    09-01 19:52:11.230: D/AndroidNative(25779): GooglePlaySupportActivity::eek:nStop
    I then updated Google Play Services in the Android SDK from 10.x.x to the latest 11.x.x. I rebuilt the app and ran it. It connected. I then closed the app and ran it again, and it failed.
    09-01 20:08:30.305: D/AndroidNative(29929): GooglePlaySupportActivity::eek:nStop
    09-01 20:08:30.305: D/AndroidNative(29929): Submiting result on activity stop
    09-01 20:08:30.306: D/AndroidNative(29929): GCM::eek:nActivityResult request 0 response 0 data null
    09-01 20:08:31.114: D/AndroidNative(29929): GooglePlaySupportActivity::eek:nStart
    09-01 20:08:37.610: D/AndroidNative(29929): GooglePlaySupportActivity::eek:nActivityResult
    09-01 20:08:37.610: D/AndroidNative(29929): GCM::eek:nActivityResultDiconnectCheck
    09-01 20:08:37.610: D/AndroidNative(29929): GamesActivityResultCodes response -1
    09-01 20:08:37.610: D/AndroidNative(29929): GCM::eek:nActivityResult request 9001 response -1 data null
    09-01 20:08:37.610: D/AndroidNative(29929): result: REQUEST_CODE_RESOLUTION resultCode:-1 Intent data: null
    09-01 20:08:37.872: D/AndroidNative(29929): Skipping Reconnection on start
    09-01 20:08:37.875: D/AndroidNative(29929): GooglePlaySupportActivity::eek:nStop
    09-01 20:08:39.150: D/AndroidNative(29929): GoogleApiClient connected
    09-01 20:08:39.163: D/AndroidNative(29929): accountName david.g.coombes@gmail.com
    09-01 20:08:39.163: D/AndroidNative(29929): onConnected: connection hint has 0 request(s)
    09-01 20:08:39.163: D/AndroidNative(29929): ************** FINAL: Google Play Connection result: 0 ************
    09-01 20:08:39.163: D/AndroidNative(29929): GameInvitationManager onConnected
    09-01 20:08:39.176: D/AndroidNative(29929): setViewForPopups
    09-01 20:08:39.177: D/AndroidNative(29929): AN_QuestUpdateListener registred
    09-01 20:08:43.015: D/AndroidNative(29929): Disconnected from play service
    09-01 20:08:43.031: D/AndroidNative(29929): GooglePlaySupportActivity::eek:nStart
    09-01 20:08:48.040: D/AndroidNative(29929): GooglePlaySupportActivity::eek:nActivityResult
    09-01 20:08:48.040: D/AndroidNative(29929): GCM::eek:nActivityResultDiconnectCheck
    09-01 20:08:48.040: D/AndroidNative(29929): GamesActivityResultCodes response 0
    09-01 20:08:48.229: D/AndroidNative(29929): Reconnection on start
    09-01 20:08:48.339: D/AndroidNative(29929): GooglePlaySupportActivity::eek:nStop
    09-01 20:08:48.705: D/AndroidNative(29929): GoogleApiClient connected
    09-01 20:08:48.710: D/AndroidNative(29929): accountName david.g.coombes@gmail.com
    09-01 20:08:48.711: D/AndroidNative(29929): onConnected: connection hint has 0 request(s)
    09-01 20:08:48.711: D/AndroidNative(29929): ************** FINAL: Google Play Connection result: 0 ************
    09-01 20:08:48.711: D/AndroidNative(29929): GameInvitationManager onConnected
    09-01 20:08:48.713: D/AndroidNative(29929): setViewForPopups
    09-01 20:08:48.713: D/AndroidNative(29929): AN_QuestUpdateListener registred
    09-01 20:08:48.713: D/AndroidNative(29929): GCM::eek:nActivityResult request 20002 response 0 data null
    09-01 20:08:50.457: D/AndroidNative(29929): Disconnected from play service
    09-01 20:09:06.716: D/AndroidNative(29673): GameClientManager: Creating New GC
    09-01 20:09:06.873: D/AndroidNative(29673): IsPlayServiceAlavliable ConnectionResult:0
    09-01 20:09:06.877: D/AndroidNative(29673): GP::sighIn accountName:null
    09-01 20:09:06.995: D/AndroidNative(29673): GooglePlaySupportActivity::eek:nStart
    09-01 20:09:06.995: D/AndroidNative(29673): GooglePlaySupportActivity onStart typeCode:GOOGLE_PLAY_CONNECTION
    09-01 20:09:06.995: D/AndroidNative(29673): GP::StartSignRequest accountName:null
    09-01 20:09:07.006: D/AndroidNative(29673): Google Play Scopes:GamesAPIPlusAPIAppInvite
    09-01 20:09:07.006: D/AndroidNative(29673): Games.API scope added
    09-01 20:09:07.006: D/AndroidNative(29673): Show Connecting Popup: true
    09-01 20:09:07.015: D/AndroidNative(29673): Plus.API scope added
    09-01 20:09:07.017: D/AndroidNative(29673): AppInvite.API scope added
    09-01 20:09:07.056: D/AndroidNative(29673): Google Play sighIn started
    09-01 20:09:07.831: D/AndroidNative(29673): *************************************************************
    09-01 20:09:07.831: D/AndroidNative(29673): *************************************************************
    09-01 20:09:07.831: D/AndroidNative(29673): *************** GOOGLE PLAY CONNECTION FAILED ***************
    09-01 20:09:07.831: D/AndroidNative(29673): ERROR CODE: 4 ***************
    09-01 20:09:07.831: D/AndroidNative(29673): HAS RESOLUTION: true ***************
    09-01 20:09:07.831: D/AndroidNative(29673): DESCRIBTION: SIGN_IN_REQUIRED - The client attempted to connect to the service but the user is not signed in. The client may choose to continue without using the API or it may call startResolutionForResult(Activity, int) to prompt the user to sign in. After the sign in activity returns with RESULT_OK further attempts to connect should succeed.
    09-01 20:09:07.831: D/AndroidNative(29673): READ MORE: http://developer.android.com/reference/com/google/android/gms/common/ConnectionResult.html
    09-01 20:09:07.831: D/AndroidNative(29673): *************************************************************
    09-01 20:09:07.831: D/AndroidNative(29673): *************************************************************
    09-01 20:09:07.973: D/AndroidNative(29673): Skipping Reconnection on start
    09-01 20:09:08.002: D/AndroidNative(29673): GooglePlaySupportActivity::eek:nStop
    09-01 20:09:08.003: D/AndroidNative(29673): Submiting result on activity stop
    09-01 20:09:08.003: D/AndroidNative(29673): GCM::eek:nActivityResult request 0 response 0 data null
    09-01 20:09:08.949: D/AndroidNative(29673): GooglePlaySupportActivity::eek:nStart
    09-01 20:09:13.858: D/AndroidNative(29673): GooglePlaySupportActivity::eek:nActivityResult
    09-01 20:09:13.858: D/AndroidNative(29673): GCM::eek:nActivityResultDiconnectCheck
    09-01 20:09:13.858: D/AndroidNative(29673): GamesActivityResultCodes response 10002
    09-01 20:09:13.858: D/AndroidNative(29673): GCM::eek:nActivityResult request 9001 response 10002 data Intent { (has extras) }
    09-01 20:09:13.860: D/AndroidNative(29673): result: REQUEST_CODE_RESOLUTION resultCode:10002 Intent data: Intent { (has extras) }
    09-01 20:09:13.862: D/AndroidNative(29673): onSignInFailed with code: 10002
    09-01 20:09:13.862: D/AndroidNative(29673): ************** FINAL: Google Play Connection result: 10002 ************
    09-01 20:09:14.097: D/AndroidNative(29673): Skipping Reconnection on start
    09-01 20:09:14.103: D/AndroidNative(29673): GooglePlaySupportActivity::eek:nStop

    I finally uninstalled the app from my phone and reinstalled it, and it connected. If I disconnect, I can reconnect.
    Okay, what if I close it...
    So if I disconnect before closing the app, I can reconnect next time I run it. But if I stay connected and close the app...yep it won't connect. That appears to be a bug. I'll update the top of this post!

    To be clear -

    Create a Connect App called com.sg.test
    Building the 9.8 example scene and link to com.sg.test
    Run it and connect fine.
    Disconnect.
    Close the app (square button to list apps, swipe away)
    Run it again
    Connect and it works
    Close the app without disconnecting
    Run it again
    Can no longer connect

    I had very similar results with Twitter where I couldn't connect even when support could. In the end they gave up and just offered me a refund. I wonder if this is related?

    Spent a whole day trying to get this to work, where I should have been releasing today. Hopefully it won't be after the weekend before you take a look at this.

    Edit: It's inconsistent. Installed on the Nexus 7. Connected and disconnected just fine. Closed the app while connected but the bug isn't kicking in and I can still connect okay.

    Edit 2: And now swapping out the demo package with my game package, I can still connect.
     
    Last edited: Sep 1, 2017
  14. SoftwareGeezers

    SoftwareGeezers

    Joined:
    Jun 22, 2013
    Posts:
    505
    Same result with a different device (nVidia Shield Tablet).

    - Try my game and it doesn't connect.
    - Try the example scene with my game's settings - doesn't connect
    - Try the example scene with app settings for a different Console app - connects
    - Try the example scene with my game's settings again - connects
    - Try my game with my game's settings - connects

    There's some aspect about the process that creates a bottleneck with certain settings preventing Google Play connection, which connecting to a different Console project seems to clear.

    As all these devices have been failing with AN 9.7 and I'm now using 9.8 with Google Play 11, it might be a solved problem.
     
  15. wangzy_88

    wangzy_88

    Joined:
    Sep 12, 2012
    Posts:
    14
    My Game stuck on Android O, there are the log:

    18914-18914/? W/Unity: UnityPlayerNativeActivity has been deprecated, please update your AndroidManifest to use UnityPlayerActivity instead
    6765-6765/? W/pool-1-temporar: type=1400 audit(0.0:12238): avc: denied { search } for name="irq" dev="proc" ino=4026542450 scontext=u:r:untrusted_app_25:s0:c512,c768 tcontext=u:eek:bject_r:proc_irq:s0 tclass=dir permissive=0
    18914-18914/? I/Unity: splash_mode = 1 (integer)
    18914-18914/? I/Unity: useObb = False (bool)
    18914-18914/? I/Unity: showSplash = True (bool)
    18914-18914/? E/Unity: Unable to query for permission: Fragment null must be a public static class to be properly recreated from instance state.
    18914-18914/? I/Unity: onResume
    18914-18938/? D/OpenGLRenderer: HWUI GL Pipeline
    18914-18938/? I/Adreno: QUALCOMM build : 7142022, Ib5823dd10c
    Build Date : 06/23/17
    OpenGL ES Shader Compiler Version: EV031.18.00.00
    Local Branch : O11A
    Remote Branch :
    Remote Branch :
    Reconstruct Branch :
    18914-18938/? I/vndksupport: sphal namespace is not configured for this process. Loading /vendor/lib/hw/gralloc.msm8992.so from the current namespace instead.
    3884-3890/? I/zygote64: Do full code cache collection, code=123KB, data=73KB
    3884-3890/? I/zygote64: After code cache collection, code=102KB, data=58KB
    18914-18938/? I/Adreno: PFP: 0x00000000, ME: 0x00000000
    18914-18914/? D/Unity: SetWindow 0 0xd8a9b808
    18914-18914/? D/Unity: SetWindow 0 0xd8a9b808
    18914-18938/? I/OpenGLRenderer: Initialized EGL, version 1.4
    18914-18938/? D/OpenGLRenderer: Swap behavior 2
    18914-18914/? I/Unity: windowFocusChanged: true
    358-358/? W//system/bin/hwservicemanager: getTransportFromManifest: Cannot find entry android.hardware.graphics.mapper@2.0::IMapper in either framework or device manifest, using default transport.
    18914-18938/? I/vndksupport: sphal namespace is not configured for this process. Loading /vendor/lib/hw/gralloc.msm8992.so from the current namespace instead.

    Only one Error: Unable to query for permission: Fragment null must be a public static class to be properly recreated from instance state.

    Please help me! Thanks a lot!
     
  16. Ryoha

    Ryoha

    Joined:
    Mar 5, 2017
    Posts:
    7
    Just wonder, when next update?
     
  17. lost9725

    lost9725

    Joined:
    Sep 19, 2017
    Posts:
    1
    I am suffering from the same issue right now.
    But, I succeeded in the building.

    Thanks.
     
    Last edited: Sep 25, 2017
  18. 3gogames

    3gogames

    Joined:
    Jul 28, 2015
    Posts:
    31
    Hi,

    after our game release we're registering many crashes like this (with Crashlytics):

    Fatal Exception: java.lang.Error: FATAL EXCEPTION [main]
    Unity version : 5.6.3f1
    Device model : samsung SM-G130BU
    Device fingerprint: samsung/young2ve3gvj/young2ve3g:4.4.4/KTU84P/G130BUVJU0APA1:user/release-keys


    Caused by java.lang.RuntimeException: Unable to stop activity {com.reludo.shootingrangechallenge/com.androidnative.gms.core.GooglePlaySupportActivity}: java.lang.NullPointerException
    at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3737)
    at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:3791)
    at android.app.ActivityThread.access$1400(ActivityThread.java:166)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1336)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:136)
    at android.app.ActivityThread.main(ActivityThread.java:5584)
    at java.lang.reflect.Method.invokeNative(Method.java)
    at java.lang.reflect.Method.invoke(Method.java:515)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)
    at dalvik.system.NativeStart.main(NativeStart.java)
    Caused by java.lang.NullPointerException
    at com.androidnative.gms.core.GameClientManager.onActivityResult(GameClientManager.java:1148)
    at com.androidnative.gms.core.GooglePlaySupportActivity.onStop(GooglePlaySupportActivity.java:80)
    at android.app.Instrumentation.callActivityOnStop(Instrumentation.java:1219)
    at android.app.Activity.performStop(Activity.java:5592)
    at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3732)
    at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:3791)
    at android.app.ActivityThread.access$1400(ActivityThread.java:166)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1336)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:136)
    at android.app.ActivityThread.main(ActivityThread.java:5584)
    at java.lang.reflect.Method.invokeNative(Method.java)
    at java.lang.reflect.Method.invoke(Method.java:515)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)
    at dalvik.system.NativeStart.main(NativeStart.java)

    Any idea? We should find a solution because many users seems to be afftected.
     
  19. omechano

    omechano

    Joined:
    Sep 12, 2014
    Posts:
    21
    Gustavo-Quiroz likes this.
  20. 3gogames

    3gogames

    Joined:
    Jul 28, 2015
    Posts:
    31
    Another question: does your plugin support Android Oreo?

    We can see this crashes on our game (using Crashlytics):

    Fatal Exception: java.lang.RuntimeException: Unable to start receiver com.androidnative.features.notifications.LocalNotificationReceiver: java.lang.IllegalStateException: Not allowed to start service Intent { cmp=com.reludo.shootingrangechallenge/com.androidnative.features.notifications.LocalNotificationService }: app is in background uid UidRecord{437ebc3 u0a1 RCVR idle procs:1 seq(0,0,0)}
    at android.app.ActivityThread.handleReceiver(ActivityThread.java:3259)
    at android.app.ActivityThread.-wrap17(Unknown Source)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1677)
    at android.os.Handler.dispatchMessage(Handler.java:105)
    at android.os.Looper.loop(Looper.java:164)
    at android.app.ActivityThread.main(ActivityThread.java:6541)
    at java.lang.reflect.Method.invoke(Method.java)
    at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)
    Caused by java.lang.IllegalStateException: Not allowed to start service Intent { cmp=com.reludo.shootingrangechallenge/com.androidnative.features.notifications.LocalNotificationService }: app is in background uid UidRecord{437ebc3 u0a1 RCVR idle procs:1 seq(0,0,0)}
    at android.app.ContextImpl.startServiceCommon(ContextImpl.java:1505)
    at android.app.ContextImpl.startService(ContextImpl.java:1461)
    at android.content.ContextWrapper.startService(ContextWrapper.java:644)
    at android.content.ContextWrapper.startService(ContextWrapper.java:644)
    at com.androidnative.features.notifications.LocalNotificationReceiver.onReceive(LocalNotificationReceiver.java:44)
    at android.app.ActivityThread.handleReceiver(ActivityThread.java:3252)
    at android.app.ActivityThread.-wrap17(Unknown Source)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1677)
    at android.os.Handler.dispatchMessage(Handler.java:105)
    at android.os.Looper.loop(Looper.java:164)
    at android.app.ActivityThread.main(ActivityThread.java:6541)
    at java.lang.reflect.Method.invoke(Method.java)
    at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:240)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:767)

    @AlexRay can you help us? We have this problem on our released game, so it's very urgent.
     
  21. shx

    shx

    Joined:
    Dec 12, 2015
    Posts:
    3
    I have the same problem as 3gogames, and I can't seem to find the source code for the .jar files to fix it myself.
     
    Last edited: Sep 23, 2017
  22. shx

    shx

    Joined:
    Dec 12, 2015
    Posts:
    3
    I think I fixed the IllegalStateException by setting the target SDK version of the project to 25. The exception is only thrown when the app explicitely targets API level 26 (aka Android 8). For that to work I had to unpack the androidnative.aar and change the target version in the embedded AndroidManifest.xml to 25. Caveat, I have no idea if and what other parts of AndroidNative get broken by that. I only use the notifications.
     
  23. 3gogames

    3gogames

    Joined:
    Jul 28, 2015
    Posts:
    31
    Thanks for the feedback @shx...Anyone from Stan's Assets can confirm the problem?
     
  24. 3gogames

    3gogames

    Joined:
    Jul 28, 2015
    Posts:
    31
    @AlexRay , any news about this crash? It seems to affect a lot of users.
     
  25. KrcKung

    KrcKung

    Joined:
    Jul 18, 2017
    Posts:
    25
    Oh wow, never know it can be unpack and modified in such a way. Gonna try it out, thanks.
     
  26. pvalium

    pvalium

    Joined:
    Oct 1, 2016
    Posts:
    19
    I have a strange behaviour related to admob when I follow these steps:
    -Open app, banners (banners and interstitial) shows ok,
    -Disable internet, banners and interstitial doesnt' show, its ok.
    -Enable internet again, banners and interstitial doesn't show, and I get an error in logcat: failed to load ad 3. Internet it's okay, I can see videos from unityads, ranking from googleplay, etc. But I get always this error, and banners never work again.

    If I close app, and reopen, banners works again.

    Somebody has this strange behaviour?
     
  27. 3gogames

    3gogames

    Joined:
    Jul 28, 2015
    Posts:
    31
    Does this hotfix works?
     
  28. KrcKung

    KrcKung

    Joined:
    Jul 18, 2017
    Posts:
    25
    So far with this fix local notifications work in android 7 ( haven't test other yet ), and it give error in android 8 ( but no crash ).
     
  29. pvalium

    pvalium

    Joined:
    Oct 1, 2016
    Posts:
    19
    HI, is possible to capture error code in load admob interstitial? The delegate OnInterstitialFailedLoading of AndroidAdMobController is not returning any data.
     
  30. Alima-Studios

    Alima-Studios

    Joined:
    Nov 12, 2014
    Posts:
    47
    So is it confirmed that local notifications are broken on last release of android native on unity 2017.2 ?

    must we wait to next release of android native ?
     
  31. Balgames

    Balgames

    Joined:
    Oct 2, 2016
    Posts:
    1
    Hi,
    Can we have some exemple for use rewarded Ads google ?
    thx :)
     
  32. BenoitFreslon

    BenoitFreslon

    Joined:
    Jan 16, 2013
    Posts:
    131
    I can't install Android Native + OneSignal SDK + Facebook SDK + Google Analytics SDK
    So many conflits and errors.
    Errors from: Android Manifest, Missing libs, Missing classes, duplicated libs
    :(
     
    Last edited: Oct 24, 2017
  33. Phuzz

    Phuzz

    Joined:
    Mar 31, 2014
    Posts:
    47
    In my IAP, after acquiring localized prices, one of my four consumables shows a wrong string format

    10.99 shows as 0.99 $

    Rest of the items return proper string value:

    0.99 = $0.99
    2.99 = $2.99
    7.99 = $7.99
    ------------------- but this one
    10.99 = 0.99 $

    Notice other than the wrong number, dollar sign is on the right side of the number with an added space. I think it has to do with the 2 digit number "10" but I do not know why. I was using a different IAP before Native Plugin where this issue did not exist, all numbers appeared normal, help please? :)
     
  34. TFG

    TFG

    Joined:
    Jan 17, 2017
    Posts:
    3
    Hi,
    I try to get AppInvite on Android and faced this error.

    AndroidJavaException: java.lang.NullPointerException: Attempt to invoke virtual method 'com.google.android.gms.common.api.GoogleApiClient com.androidnative.gms.core.NewGameHelper.getGoogleApiClient()' on a null object reference
    11-15 14:55:32.069 25709 25709 E Unity : java.lang.NullPointerException: Attempt to invoke virtual method 'com.google.android.gms.common.api.GoogleApiClient com.androidnative.gms.core.NewGameHelper.getGoogleApiClient()' on a null object reference
    11-15 14:55:32.069 25709 25709 E Unity : at com.androidnative.gms.core.GameClientManager.API(GameClientManager.java:210)
    11-15 14:55:32.069 25709 25709 E Unity : at com.androidnative.gms.core.AppInvitesController.getInvitation(AppInvitesController.java:101)
    11-15 14:55:32.069 25709 25709 E Unity : at com.unity3d.player.ReflectionHelper.nativeProxyInvoke(Native Method)
    11-15 14:55:32.069 25709 25709 E Unity : at com.unity3d.player.ReflectionHelper.a(Unknown Source)
    11-15 14:55:32.069 25709 25709 E Unity : at com.unity3d.player.ReflectionHelper$1.invoke(Unknown Source)
    11-15 14:55:32.069 25709 25709 E Unity : at java.lang.reflect.Proxy.invoke(Proxy.java:813)
    11-15 14:55:32.069 25709 25709 E Unity : at $Proxy3.run(Unknown Source)
    11-15 14:55:32.069 25709 25709 E Unity : at android.os.Handler.handleCallback(Handler.java:751)
    11-15 14:55:32.069 25709 25709 E Unity : at android.os.Handler.dispatchMessage(Handler.java:95)
    11-15 14:55:32.069 25709 25709 E Unity : at android.os.Loope

    Could you help me, please?
     
  35. BenoitFreslon

    BenoitFreslon

    Joined:
    Jan 16, 2013
    Posts:
    131
    Hello,

    Is it possible to display "emojis" to the Native popup ? like : or

    I got a crash when I try to use emojis in the AndroidMessage.Create method.
     
  36. Design3DGame

    Design3DGame

    Joined:
    Nov 24, 2016
    Posts:
    19
    We found out that "purchase data" and "data signature" is outputted in LogCat after In-App Purchase operation completion although option Debug.logger.logEnabled=false in our Unity project.

    AndroidManifest.xml file debug option is set to android:debuggable="false".

    "Script Debugging" and "Development Build" options are turned off in "Build Settings" dialog window.

    Please, give your advice how to avoid "purchase data" and "data signature" output in LogCat after In-App Purchase operation completion since it is not appropriate in our case.
     
  37. daniel-choi

    daniel-choi

    Joined:
    Apr 13, 2015
    Posts:
    5
    android native plugin ver 9.9/22
    unity 2017.2.0f3

    AN: Using proxy for class: androidnative.firebase.analytics.Brige.methode:init
    Excecpition:No such proxy method: UnityEngine.AndroidJavaRunnableProxy.run()
    AN: Using proxy for class: androidnative.gms.ad.ANMobileAd.methode:Bridge_init
    Excecpition:No such proxy method: UnityEngine.AndroidJavaRunnableProxy.run()

    how can fix it??
     
  38. nedhaljalali

    nedhaljalali

    Joined:
    Sep 14, 2017
    Posts:
    7
    after i installed the app i try one of the examples scene but the popup and the toast did not work in unity ,, but it works fine in the mobile can you explain why pls ? thank you
     
  39. fornetjob

    fornetjob

    Joined:
    Sep 11, 2014
    Posts:
    14
    I try build firebase for android and got some errors:

    CommandInvokationFailure: Unable to merge android manifests. See the Console for more details. C:/Program Files (x86)/Java/jdk1.7.0_55\bin\java.exe -Xmx1024M -Dcom.android.sdkmanager.toolsdir="C:/Android/Sdk\tools" -Dfile.encoding=UTF8 -jar "C:\Program Files\Unity_5.5.0p4\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" - stderr[ Error: [Temp\StagingArea\AndroidManifest-main.xml:21, C:\Develop\Defender5\Temp\StagingArea\android-libraries\firebase-common\AndroidManifest.xml:5] Trying to merge incompatible /manifest/application/provider[@name=com.google.firebase.provider.FirebaseInitProvider] element: <provider -- @android:authorities="com.fornetjob.DefenderZ.firebaseinitprovider" <provider ++ @android:authorities="${applicationId}.firebaseinitprovider" Error: [Temp\StagingArea\AndroidManifest-main.xml:6, C:\Develop\Defender5\Temp\StagingArea\android-libraries\firebase-iid\AndroidManifest.xml:15] Trying to merge incompatible /manifest/application/receiver[@name=com.google.firebase.iid.FirebaseInstanceIdReceiver] element: <receiver @android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver" <intent-filter> @android:name="com.google.android.c2dm.intent.RECEIVE"> -- <action -- @android:name="com.google.android.c2dm.intent.REGISTRATION"> -- </action> <receiver @android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver" <intent-filter> @android:name="com.google.android.c2dm.intent.RECEIVE"> ++ <category ++ @android:name="${applicationId}"> ++ </category> ] stdout[ [Temp\StagingArea\AndroidManifest-main.xml, C:\Develop\Defender5\Temp\StagingArea\android-libraries\firebase-analytics-impl\AndroidManifest.xml:12] Skipping identical /manifest/application/service[@name=com.google.android.gms.measurement.AppMeasurementService] element. [Temp\StagingArea\AndroidManifest-main.xml, C:\Develop\Defender5\Temp\StagingArea\android-libraries\firebase-analytics-impl\AndroidManifest.xml:10] Skipping identical /manifest/application/receiver[@name=com.google.android.gms.measurement.AppMeasurementReceiver] element. [Temp\StagingArea\AndroidManifest-main.xml:13, C:\Develop\Defender5\Temp\StagingArea\android-libraries\firebase-iid\AndroidManifest.xml:26] Skipping identical /manifest/application/service[@name=com.google.firebase.iid.FirebaseInstanceIdService] element. [Temp\StagingArea\AndroidManifest-main.xml:5, C:\Develop\Defender5\Temp\StagingArea\android-libraries\firebase-iid\AndroidManifest.xml:23] Skipping identical /manifest/application/receiver[@name=com.google.firebase.iid.FirebaseInstanceIdInternalReceiver] element. [Temp\StagingArea\AndroidManifest-main.xml:35, C:\Develop\Defender5\Temp\StagingArea\android-libraries\play-services-ads-lite\AndroidManifest.xml:10] Skipping identical /manifest/application/activity[@name=com.google.android.gms.ads.AdActivity] element. [Temp\StagingArea\AndroidManifest-main.xml:18, C:\Develop\Defender5\Temp\StagingArea\android-libraries\play-services-basement\AndroidManifest.xml:5] Skipping identical /manifest/application/meta-data[@name=com.google.android.gms.version] element. ] exit code: 1 UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) UnityEditor.Android.AndroidSDKTools.RunCommandInternal (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) UnityEditor.Android.AndroidSDKTools.RunCommandSafe (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) UnityEditor.HostView:OnGUI()
     
    Deleted User likes this.
  40. Stans-Assets

    Stans-Assets

    Joined:
    Jun 20, 2014
    Posts:
    57
    Hey, guys!
    We are so sorry for the delay in answering for your questions оn the forum. Now we do not have enough stаff and time to answer here. But very soon we will be back:cool: Write to our service of support support@stansassets.com.
    Also there will be a live stream in January! So vote here, and we will choose a topic for the live training! See you!
     
  41. BoboShu

    BoboShu

    Joined:
    Nov 20, 2014
    Posts:
    38
    5.6.4p4 .Plugin v9.10_24

    FAILURE: Build failed with an exception.
    * What went wrong:
    Execution failed for task ':processDebugResources'.
    > Error: more than one library with package name 'com.stansassets.androidnative'
    * Try:
     
    BenoitFreslon likes this.
  42. Deleted User

    Deleted User

    Guest

    Unity 5.5.0 Plugin v9.10_24

    Build Failed : Unable to merge android manifests

    I m using Firebase Features.
    i have replace the bundle id given in project setting in android manifest, but also it gives me these error.
    Can u suggest me solution for these firebase feature.

    CommandInvokationFailure: Unable to merge android manifests. See the Console for more details.
    C:/Program Files/Java/jdk1.8.0_144\bin\java.exe -Xmx2048M -Dcom.android.sdkmanager.toolsdir="C:/Users/Sagar-Idc/AppData/Local/Android/sdk\tools" -Dfile.encoding=UTF8 -jar "E:\Unity 2017.2.0p4\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" -

    stderr[
    Error: [Temp\StagingArea\AndroidManifest-main.xml:38, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\firebase-common\AndroidManifest.xml:5] Trying to merge incompatible /manifest/application/provider[@name=com.google.firebase.provider.FirebaseInitProvider] element:
    <provider
    -- @android:authorities="com.hardparkingcargame.parkinggame.firebaseinitprovider"
    <provider
    ++ @android:authorities="${applicationId}.firebaseinitprovider"
    Error: [Temp\StagingArea\AndroidManifest-main.xml:24, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\firebase-iid\AndroidManifest.xml:15] Trying to merge incompatible /manifest/application/receiver[@name=com.google.firebase.iid.FirebaseInstanceIdReceiver] element:
    <receiver
    @android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver"
    <intent-filter>
    @android:name="com.google.android.c2dm.intent.RECEIVE">
    -- <action
    -- @android:name="com.google.android.c2dm.intent.REGISTRATION">
    -- </action>
    <receiver
    @android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver"
    <intent-filter>
    @android:name="com.google.android.c2dm.intent.RECEIVE">
    ++ <category
    ++ @android:name="${applicationId}">
    ++ </category>
    ]
    stdout[
    [Temp\StagingArea\AndroidManifest-main.xml, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\firebase-analytics-impl\AndroidManifest.xml:12] Skipping identical /manifest/application/service[@name=com.google.android.gms.measurement.AppMeasurementService] element.
    [Temp\StagingArea\AndroidManifest-main.xml, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\firebase-analytics-impl\AndroidManifest.xml:10] Skipping identical /manifest/application/receiver[@name=com.google.android.gms.measurement.AppMeasurementReceiver] element.
    [Temp\StagingArea\AndroidManifest-main.xml:33, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\firebase-iid\AndroidManifest.xml:26] Skipping identical /manifest/application/service[@name=com.google.firebase.iid.FirebaseInstanceIdService] element.
    [Temp\StagingArea\AndroidManifest-main.xml:23, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\firebase-iid\AndroidManifest.xml:23] Skipping identical /manifest/application/receiver[@name=com.google.firebase.iid.FirebaseInstanceIdInternalReceiver] element.
    [Temp\StagingArea\AndroidManifest-main.xml:50, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\play-services-ads-lite\AndroidManifest.xml:10] Skipping identical /manifest/application/activity[@name=com.google.android.gms.ads.AdActivity] element.
    [Temp\StagingArea\AndroidManifest-main.xml:6, E:\Sagar\FinalProjects\Demo\Hard Driving Car Game\Temp\StagingArea\android-libraries\play-services-basement\AndroidManifest.xml:5] Skipping identical /manifest/application/meta-data[@name=com.google.android.gms.version] element.
    ]
    exit code: 1
    UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.RunCommandInternal (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEditor.Android.AndroidSDKTools.RunCommandSafe (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr)
     
    Last edited by a moderator: Jan 3, 2018
  43. Deleted User

    Deleted User

    Guest


    GoogleAdMobTab Script has been given in Android Native Plugin .
    It is Located in Plugins\StansAssets\Modules\AndroidNative\xExample\Scripts\AdMob.
    U can find Example of rewarded ads for google in that script.
     
  44. Arkade

    Arkade

    Joined:
    Oct 11, 2012
    Posts:
    570
    Hi
    Does Stan's Assets' Native provide a TTS facility? I have looked but can't seem to find. Sorry if being blind!
    Thanks!
     
  45. InfinityCoder88

    InfinityCoder88

    Joined:
    Oct 4, 2013
    Posts:
    241
    I need this too, Speech To Text / Text To Speech. Thanks!
     
  46. Ramsdal

    Ramsdal

    Joined:
    Oct 18, 2013
    Posts:
    250
    @AlexRay Plugin deprecated? can you elaborate a bit on what this means and why?
     
  47. recon0303

    recon0303

    Joined:
    Apr 20, 2014
    Posts:
    1,598

    Ya I like to know the answer as well, right in the middle of development, been using this.
     
  48. Richardbmth

    Richardbmth

    Joined:
    Mar 5, 2016
    Posts:
    29
    recon0303 likes this.
  49. recon0303

    recon0303

    Joined:
    Apr 20, 2014
    Posts:
    1,598
    I talk to Stan it was a mistake/ issue, that they are resolving, and update is coming soon as well, this is right from STAN....on Skype.
     
  50. nedhaljalali

    nedhaljalali

    Joined:
    Sep 14, 2017
    Posts:
    7
    hi all
    i wanna use (Android Native Plugin) to upload and download file from (Google Drive API) ..
    like saving database as file or backup it.
    do think it will work ?
    if anyone can help ..
    thank you .
     
    Last edited: Feb 20, 2018