Search Unity

  1. Unity 2019.1 beta is now available.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. We're looking for insight from anyone who has experience with game testing to help us better Unity. Take our survey here. If chosen to participate you'll be entered into a sweepstake to win an Amazon gift card.
    Dismiss Notice
  4. On February 28th the Feedback website will shut down and be redirected to the Unity forums. See the full post for more information.
    Dismiss Notice
  5. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  6. Unity 2018.3 is now released.
    Dismiss Notice
  7. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

[Released] Android Native Plugin

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

  1. Dreamonaut

    Dreamonaut

    Joined:
    May 19, 2014
    Posts:
    32
    Hello mates,

    I'm integrating in app billing in my game and i got an issue whenever i want to purchase an item , the Google Play store crashes, then the game crashes also.

    I have latest AndroidNative version and Google Play Store v 6.0.0.

    I tried the in app billing with an older Google Play Store version (v4.x.x) and it works fine ! ! so i'm wondering if the issue is in google play store latest version ?

    Anyone facing the exact same issue ?

    Thank you in advance ! !
     
  2. jprocha101

    jprocha101

    Joined:
    Apr 8, 2015
    Posts:
    134
    @Dreamonaut I have a similar issue, but it only happens when I have "development build" checked. If I uncheck it then everything works as expected.

    That sounds more like a unity issue than this asset. Any java call to play services causes the app to crash. It only happens on Android 6.0, anything less works just fine.
     
  3. Dreamonaut

    Dreamonaut

    Joined:
    May 19, 2014
    Posts:
    32
    @jprocha101
    Thank you for the answer ! ! unfortunately i'm not in development build and i still get this issue. I don't really know what to do, i think i can just wait for a google play store update ? ...
     
  4. Dr. Argento

    Dr. Argento

    Joined:
    Jan 29, 2015
    Posts:
    23
    @AlexRay @D0R1N Any news about the example ?
     
  5. InfinityCoder88

    InfinityCoder88

    Joined:
    Oct 4, 2013
    Posts:
    234
  6. ilmario

    ilmario

    Joined:
    Feb 16, 2015
    Posts:
    69
    Hi,
    I just bought the Android Native Plugin. There are other very good assets that offer easy implementation of cloud services such as achievements, saved games, preferences etc on Google Play/Amazon (and even iOS). But they were missing some features I require, such as Google Play game gifts, which seem to be supported in this asset (great!).

    There is one rather new but very promising feature for Google Play (+ iOS), which is App-invites. It doesnt seem like its supported yet in your assett, as it has been out only some months. But is it on the todo-list for the android-plugin? I believe gifts+invites will become a killer app(feature) in the near future.

    More info about app-invites:
    https://developers.google.com/app-invites/
    http://forum.unity3d.com/threads/implementing-app-invites-by-google.330641/
    https://stackoverflow.com/questions/tagged/google-app-invites
     
  7. Nekura42

    Nekura42

    Joined:
    Nov 11, 2012
    Posts:
    2
    Hi,
    I'm using the AdMob feature of the plug-in to show a small ad banner (not the interstitial) at the bottom of the screen. The ad shows up fine, but nothing happens when I tap on it. Any suggestions?
     
  8. jprocha101

    jprocha101

    Joined:
    Apr 8, 2015
    Posts:
    134
    @Nekura42 in your Android manifest make sure this value is set to true.

    <meta-data android:name="unityplayer.ForwardNativeEventsToDalvik" android:value="true"/>
     
    Nekura42 and AlexRay like this.
  9. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    I have good news for you!

    I want to say, that App Invites are in Android Native New Features list.
    So, I think App Invites will be available in following plugin update.
    Please, keep looking forward to future updates. Great features are coming!

    Best regards,
    Alex
     
  10. Nekura42

    Nekura42

    Joined:
    Nov 11, 2012
    Posts:
    2
    That fixed it!! Thank you so much!
     
  11. 0xsven

    0xsven

    Joined:
    Mar 5, 2015
    Posts:
    18
    I upgraded to 7.2

    The inspector still says 7.1.1 (I did a clean install)

    On the device I get a fatal error:

    E/AndroidRuntime(25609): FATAL EXCEPTION: Thread-2017
    E/AndroidRuntime(25609): java.lang.Error: FATAL EXCEPTION [Thread-2017]
    E/AndroidRuntime(25609): Unity version : 5.2.3p1
    E/AndroidRuntime(25609): Device model : samsung Galaxy Nexus
    E/AndroidRuntime(25609): Device fingerprint: google/takju/maguro:4.3/JWR66Y/776638:user/release-keys
    E/AndroidRuntime(25609):
    E/AndroidRuntime(25609): Caused by: java.lang.NullPointerException
    E/AndroidRuntime(25609): at com.androidnative.billing.core.BillingHelper.querySkuDetails(BillingHelper.java:842)
    E/AndroidRuntime(25609): at com.androidnative.billing.core.BillingHelper.queryInventory(BillingHelper.java:516)
    E/AndroidRuntime(25609): at com.androidnative.billing.core.BillingHelper.queryInventory(BillingHelper.java:489)
    E/AndroidRuntime(25609): at com.androidnative.billing.core.BillingHelper$2.run(BillingHelper.java:569)
    E/AndroidRuntime(25609): at java.lang.Thread.run(Thread.java:841)

    Will try to downgrade soon I guess
     
  12. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    It looks like some Asset Store update issue takes place.
    It will not affect any of the plugin functionality.

    This issue has been fixed in the latest plugin version.
    Most likely AndroidNative native libraries were not updated during install.
    Please, try to reinstall the plugin and retest the application.

    Best regards,
    Alex
     
  13. InfinityCoder88

    InfinityCoder88

    Joined:
    Oct 4, 2013
    Posts:
    234
    Hi @AlexRay ,

    How about my question, any news:

    Can you please provide me an example how to write data for google cloud save, I got stuck with "writing a saved game data" for google cloud, I tried and tested SavedGamesExample but can't figure out how to write data, for example:

    int points = 20;
    int bullets = 15;
    float time = 120f;


    * how to write this values into data for google cloud save ?
    Thanks in advance !
     
  14. Dr. Argento

    Dr. Argento

    Joined:
    Jan 29, 2015
    Posts:
    23
    @AlexRay Yes, please.. I can send one parameter (for example COINS or something similar) but i don't know how i can SEND and LOAD VARIOUS parameters as @D0R1N said:

    all in one byte/data or something like that.
     
  15. ilmario

    ilmario

    Joined:
    Feb 16, 2015
    Posts:
    69
    Thats fantastic news, thank you :) Any ETA on this feature? I believe app-invites can be a killer feature for some apps/games. It doesnt seem to be widely known yet.
     
  16. bekiryanik

    bekiryanik

    Joined:
    Jul 6, 2014
    Posts:
    166
    Hello,

    I am trying to implement Android In-App purchases to my project. I set everything and it seems that everything works fine except one thing. I am going to sell coins in my game and after one time that i purchase an item, i can't buy it again. It says that "Product is already owned". How can i prevent this and buy an item more than one?

    Best regards.
    Have a great day.
     
  17. jprocha101

    jprocha101

    Joined:
    Apr 8, 2015
    Posts:
    134
    @bekiryanik You need to check the "consumable" check box. It is next to you where you enter the item id in the inspector.

    You can read more about product types here:
    http://developer.android.com/intl/ko/google/play/billing/api.html#consume
     
  18. bekiryanik

    bekiryanik

    Joined:
    Jul 6, 2014
    Posts:
    166
    @jprocha101 Thank you for your quick answer.
    There is no "consumable" check box in the inspector in the place where i enter the item id. Can i enable it with with the script?
     
  19. jprocha101

    jprocha101

    Joined:
    Apr 8, 2015
    Posts:
    134
    @bekiryanik Sorry, it is not a checkbox, it is a drop down menu. Make sure it is set to consumable.

    upload_2015-12-6_12-25-6.png
     
  20. bekiryanik

    bekiryanik

    Joined:
    Jul 6, 2014
    Posts:
    166
    Thank you @jprocha101 . I think i must update my plugin first. :)
     
    jprocha101 likes this.
  21. Log_N

    Log_N

    Joined:
    Jun 17, 2015
    Posts:
    5
    Hi guys,

    I have a problem with push notification when the icon is still default one instead of one that I set in inspector.
    Can you please help me with this? What may be the reason of this?
    ico is png 256x256px file
     
  22. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    This new feature will be released with following plugin update I think.
    It should take two or three weeks.

    So, keep looking forward to new great features!

    Best regards,
    Alex
     
    ilmario likes this.
  23. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    If you want to use push notifications custom resources such as icons, sounds etc. you should call
    Code (CSharp):
    1. GoogleCloudMessageService.Instance.Init();
    method to apply your Android Native Settings for push notifications.

    Did you follow these guidelines in you project?

    Cheers!
     
  24. Log_N

    Log_N

    Joined:
    Jun 17, 2015
    Posts:
    5
    Thanks, I'll doublecheck it. I may have missed it indeed.
     
  25. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    There are two approaches how to provide data bundle for CreateNewSnapshot method of GooglePlaySavedGamesManager class.

    1. JSON Data Package. Make your data bundle as Dictionary and Serialize as JSON string.
    Save data example:
    Code (CSharp):
    1. int points = 20;
    2. int bullets = 15;
    3. float time = 120f;
    4.  
    5. Dictionary<string, object> JsonData = new Dictionary<string, object>();
    6. JsonData.Add("points", points);
    7. JsonData.Add("bullets", bullets);
    8. JsonData.Add("time", time);
    9.  
    10. string data = ANMiniJSON.Json.Serialize(JsonData);
    11. GooglePlaySavedGamesManager.Instance.CreateNewSnapshot("Name", "Dexscription", coverImage, data, playedTime);
    Read data from snapshot:
    Code (CSharp):
    1. Dictionary<string, object> JsonDeserialized = ANMiniJSON.Json.Deserialize(dataFromSnapshot) as Dictionary<string, object>;
    2.         foreach(KeyValuePair<string, object> pair in JsonDeserialized) {
    3.             Debug.Log(string.Format("{0} {1}", pair.Key, pair.Value));
    4.         }
    2. Send data as an array of bytes. Create Memory Stream, Write and Read for/from it.
    Save data sample:
    Code (CSharp):
    1. MemoryStream stream = new MemoryStream();
    2. BinaryWriter writer = new BinaryWriter(stream);
    3.  
    4. writer.Write(points);
    5. writer.Write(bullets);
    6. writer.Write(time);
    7.  
    8. byte[] buffer = stream.GetBuffer();
    9. GooglePlaySavedGamesManager.Instance.CreateNewSnapshot("Name", "Dexscription", coverImage, buffer, playedTime);
    Read data from snapshot:
    Code (CSharp):
    1. MemoryStream receivedData = new MemoryStream(snapshotBuffer);
    2. BinaryReader reader = new BinaryReader(receivedData);
    3.  
    4. Debug.Log ("Points: " + reader.ReadInt32());
    5. Debug.Log ("Bullets: " + reader.ReadInt32());
    6. Debug.Log ("Time: " + reader.ReadSingle());
    That's common approaches how to save read data to/from Game Snapshot.
    If you have any additional questions - I am open to the conversations.

    Best regards,
    Alex
     
    InfinityCoder88 likes this.
  26. Log_N

    Log_N

    Joined:
    Jun 17, 2015
    Posts:
    5
    This is what I'm calling:

    GoogleCloudMessageService.Instance.RgisterDevice();
    GoogleCloudMessageService.Instance.InitPushNotifications();

    There is no 'init' method. Issue is still there.
     
  27. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    It looks like you use old plugin version.
    Please, contact Support Team to provide you the latest plugin version and any other assistance.

    Cheers!
     
  28. InfinityCoder88

    InfinityCoder88

    Joined:
    Oct 4, 2013
    Posts:
    234
    Thanks a lot @AlexRay , for your example and support I will give'it a try, and let you know my results !

    Have a nice day !
     
  29. Dr. Argento

    Dr. Argento

    Joined:
    Jan 29, 2015
    Posts:
    23
    @AlexRay Thanx Alex, i opted for the byte solution and its working like a charm. Now i have simple question, how i can save/load directly without confirmation (OnSpanshotLoadDialogComplete/dialog.ActionComplete)?
     
  30. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    561
    @AlexRay Is that really still called OnSpanshotLoadDialogComplete? Should be Snapshot.

    I mentioned this typo, which was all over Android Native, a year or so ago. Many of the occurrences were fixed, but I guess this one slipped through.
     
  31. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    Please, take a look at Loading available Snapshots guide.
    You should load all available screenshots and enumerate through them
    Code (CSharp):
    1. GooglePlaySavedGamesManager.ActionAvailableGameSavesLoaded += ActionAvailableGameSavesLoaded;
    2. GooglePlaySavedGamesManager.Instance.LoadAvailableSavedGames();
    3.  
    4. private void ActionAvailableGameSavesLoaded (GooglePlayResult res) {
    5.     GooglePlaySavedGamesManager.ActionAvailableGameSavesLoaded -= ActionAvailableGameSavesLoaded;
    6.     if(res.IsSuccess) {
    7.         foreach(GP_SnapshotMeta meta in GooglePlaySavedGamesManager.Instance.AvailableGameSaves) {
    8.                 // YOUR LOGIC HERE!
    9.         }
    10.     } else {
    11.         AndroidMessage.Create("Fail", "Available Game Saves Load failed");
    12.     }
    13. }
    Great guide how to save new Snapshots you can find here.

    Best regards,
    Alex
     
  32. SpaceKitty

    SpaceKitty

    Joined:
    Feb 3, 2015
    Posts:
    3
    Same problem with Android, I tried 128x128 png icon, and I still see the default one for Push messages. I can see that the image gets copied in Plugins/Android/res/drawable. Maybe there is something I should add to the manifest manually?
     
  33. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    The same question for you.
    If you want to use push notifications custom resources such as icons, sounds etc. you should call
    Code (CSharp):
    1. GoogleCloudMessageService.Instance.Init();
    method to apply your Android Native Settings for push notifications.
    Did you follow these guidelines in you project?

    Cheers!
     
  34. n0nam3

    n0nam3

    Joined:
    May 12, 2015
    Posts:
    2
    Hello,

    Thanks for a great plugin, but I have a few question.

    1) Why I downloaded version 7.2 but in settings I see that plugin version is 7.1.1?
    2) In asset server I see that "Source Code is Open", so where I can find eclipse project?
    3) I have problem with push notification icon, I set icon, GoogleCloudMessageService.Instance.Init(); , but in push this icon is completly white circle, not my yellow icon with logo, can you help me with this?

    Best Regards!
     
  35. Grafos

    Grafos

    Joined:
    Aug 30, 2011
    Posts:
    202
    1) Got the same issue. Same for iOSnative's latest update, version numbers are not updated.
    Also:
    Removing androidnative removed every single setting, product etc. I had filled, had to manually put everything back in.
    Facebook's FeedShare was causing my app to crash.

    After three days of hair pulling I decided to just get back to my 7.1.1 backup. Updating this plugin has most of the time been anything but smooth, hope you pay more attention to it.
     
  36. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    I think some issues with Asset Store update take place.
    There are no reasons to worry about. It will not harm any of your functionality.

    You may request the latest source code archive via e-mail support@stansassets.com, The Stan's Assets Support Team.

    My recommendation for you to contact support team for assistance with this case.
    You will get qualified feedback shortly.

    Best regards,
    Alex
     
    InfinityCoder88 likes this.
  37. n0nam3

    n0nam3

    Joined:
    May 12, 2015
    Posts:
    2
    Thanks!
     
  38. 0xsven

    0xsven

    Joined:
    Mar 5, 2015
    Posts:
    18
    I have implemented In-App-Purchases with Android Native. I can purchase products but the callback is not being called:

    public void OnPurchaseFinishedCallback(string data)

    So I have to close and restart the app to get my purchase. Any idea why this happens?

    My code:
    // on awake:
    AndroidInAppPurchaseManager.ActionProductPurchased += OnProductPurchased;
    AndroidInAppPurchaseManager.ActionBillingSetupFinished += OnBillingConnected;
    AndroidInAppPurchaseManager.Instance.LoadStore();

    private static void OnProductPurchased (BillingResult result) {
    Debug.Log("Why is this never called????");​
    }
    I tested on Android 4.3

    Best regards,
    Sven
     
  39. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    Let's try to clarify this case.
    Did you actually call AndroidInAppPurchaseManager.Instance.Purchase method?

    Please, check it on your own.

    Best regards,
    Alex
     
  40. 0xsven

    0xsven

    Joined:
    Mar 5, 2015
    Posts:
    18
    Yes I did. And it works! But callback is not called.

    This is logcat output:

    I/Unity (14585): AN: Using proxy for class: com.androidnative.popups.PopUpsManager method:ShowPreloader
    I/Unity (14585):
    I/Unity (14585): (Filename: ./artifacts/generated/common/runtime/UnityEngineDebugBindings.gen.cpp Line: 64)
    I/Unity (14585):
    D/AndroidNative(14585): ShowPreloader:
    I/Unity (14585): AN: Using proxy for class: com.androidnative.billing.core.BillingManager method:AN_Purchase
    I/Unity (14585):
    I/Unity (14585): (Filename: ./artifacts/generated/common/runtime/UnityEngineDebugBindings.gen.cpp Line: 64)
    I/Unity (14585):
    D/AndroidNative(14585): Billing purchase com.hello.ducklings.redcanyon
    I/ActivityManager( 375): START u0 {cmp=com.hello.ducklings/com.androidnative.billing.core.AN_BillingProxyActivity (has extras)} from pid 14585
    D/AndroidNative(14585): AN_BillingProxyActivity::eek:nCreate
    D/AndroidNative(14585): launchPurchaseFlow...
    D/AndroidNative(14585): Constructing buy intent for com.hello.ducklings.redcanyon, item type: inapp
    D/Finsky (14215): [852] InAppBillingUtils.getPreferredAccount: com.hello.ducklings: Account determined from installer data - [d-1-ihxniEqfIUi4tSRd1ybuEpQ]
    D/AndroidNative(14585): Launching buy intent for com.hello.ducklings.redcanyon. Request code: 999
    I/ActivityManager( 375): START u0 {cmp=com.android.vending/com.google.android.finsky.billing.lightpurchase.IabV3Activity (has extras)} from pid -1
    D/AndroidNative(14585): Starting async operation: launchPurchaseFlow
    I/Keyboard.Facilitator( 528): onFinishInput()
    I/ActivityManager( 375): Displayed com.hello.ducklings/com.androidnative.billing.core.AN_BillingProxyActivity: +543ms
    I/ActivityManager( 375): Displayed com.android.vending/com.google.android.finsky.billing.lightpurchase.IabV3Activity: +363ms
    I/qtaguid (14215): Failed write_ctrl(u 39) res=-1 errno=22
    I/qtaguid (14215): Untagging socket 39 failed errno=-22
    W/NetworkManagementSocketTagger(14215): untagSocket(39) failed with errno -22
    D/dalvikvm(14215): GC_CONCURRENT freed 3297K, 18% free 15989K/19320K, paused 16ms+7ms, total 146ms
    D/dalvikvm(14215): WAIT_FOR_CONCURRENT_GC blocked 28ms
    I/qtaguid (14215): Failed write_ctrl(u 39) res=-1 errno=22
    I/qtaguid (14215): Untagging socket 39 failed errno=-22
    W/NetworkManagementSocketTagger(14215): untagSocket(39) failed with errno -22
    D/Finsky (14215): [1] LibraryReplicatorsImpl$4.run: Applying library update: account=[d-1-ihxniEqfIUi4tSRd1ybuEpQ]
    D/Finsky (14215): [1] ContentSyncService$3.onMutationsApplied$12348bc5: App library has changed, requesting content sync.
    D/Finsky (14215): [1] PurchaseFragment.onStateChange: Purchase succeeded
    D/dalvikvm( 375): GC_FOR_ALLOC freed 1479K, 38% free 19970K/31820K, paused 130ms, total 131ms
    D/AndroidNative(14585): AN_BillingProxyActivity::eek:nActivityResult(999, -1, Intent { (has extras) }
    D/AndroidNative(14585): Ending async operation: launchPurchaseFlow
    D/AndroidNative(14585): Successful resultcode from purchase activity.
    D/AndroidNative(14585): Purchase data: {"orderId":"GPA.1321-8177-8137-34618","packageName":"com.hello.ducklings","productId":"com.hello.ducklings.redcanyon","purchaseTime":1449669913587,"purchaseState":0,"purchaseToken":"bghgbjohnepenimknpifbobj.AO-J1OzT5pS0wscbDF-ID270Ps57gMdl8bnC2zCFMOH771_bmoWPc-Yker49pVfg5cHvGIoS31s01xzzlRdRJGrXexHfKMQQgcCERVpnoVkBNdqAup1DFDuB23IVxOKpOiXJ60WPAzGwUASavs_QTXs3HYSEFqnoxw"}
    D/AndroidNative(14585): Data signature: OzVhr/d8JZhPMkkzfh37uaC**********yYy6NSYDoCiaxmSlLVv/ZnMxlRAkiwdKKk16w/SsPg==
    D/AndroidNative(14585): Extras: Bundle[{INAPP_PURCHASE_DATA={"orderId":"GPA.1321-8177-8137-34618","packageName":"com.hello.ducklings","productId":"com.hello.ducklings.redcanyon","purchaseTime":1449669913587,"purchaseState":0,"purchaseToken":"bghgbjohnepenimknpifbobj.AO-J1O**********Fqnoxw"}, INAPP_DATA_SIGNATURE=OzVhr/d8JZhPMkkz**********k16w/SsPg==, RESPONSE_CODE=0}]
    D/AndroidNative(14585): Expected item type: inapp
    D/AndroidNative(14585): Purchase signature successfully verified.
    D/AndroidNative(14585): **AN_PurchaseFinishedListener :: Purchase finished**: Success (response: 0:OK)
    D/AndroidNative(14585): **AN_PurchaseFinishedListener :: result.isSuccess(): true
    D/AndroidNative(14585): **AN_PurchaseFinishedListener :: purchase.getSku(): com.hello.ducklings.redcanyon
    D/AndroidNative(14585): **AN_PurchaseFinishedListener added to inventory
    D/AndroidNative(14585): Finish AN_BillingProxyActivity broadcast was received
    D/dalvikvm( 375): GC_FOR_ALLOC freed 813K, 37% free 20282K/31820K, paused 82ms, total 82ms
    D/AndroidNative(14585): AN_BillingProxyActivity::eek:nStop
    D/AndroidNative(14585): AN_BillingProxyActivity::eek:nDestroy
    D/Finsky (14215): [874] AppStatesReplicator.handleContentSyncResponse: Completed 0 account content syncs with 0 successful.
    D/Finsky (14215): [1] ContentSyncService$5.onFinished: Installation state replication succeeded.
    D/AlarmManagerService( 375): Kernel timezone updated to -60 minutes west of GMT
    I/PowerManagerService( 375): Going to sleep due to screen timeout...
     
  41. Unititi

    Unititi

    Joined:
    Mar 6, 2013
    Posts:
    20
    I have a question. I hope to share screenshot for instagram only. User have to select instagram only except facebook,twitter,etc. plz help me.
     
  42. 0xsven

    0xsven

    Joined:
    Mar 5, 2015
    Posts:
    18
  43. Dr. Argento

    Dr. Argento

    Joined:
    Jan 29, 2015
    Posts:
    23
    When I import the package to my existing project, I get these two errors:

    but if I import to a blank project I do not get errors... anyone know what may be the cause?

    PS: Unity 5.3.0 | Android Native Plugin 7.2 | Plugins in use: Anti-Cheat Toolkit and M2H Localization Package.


    @AlexRay @D0R1N
     
  44. churi24

    churi24

    Joined:
    Sep 17, 2013
    Posts:
    65
    This asset is a headache, at least for me..
    I've tested this asset alone, on a clean new project.
    I'm using Unity 5.2.1f1, Android SDK Build Tool 23.0.1.
    Android Native Settings version : 7.1.1, but on asset store it figures as 7.2
    Manifest Manager Version: 1.5
    The previous version works fine but, on this, appears a new Manifest on AN_Res and this manifest gives me problems.
    The error was on compile time. Any idea?

    stderr[Error: [Temp\StagingArea\AndroidManifest-main.xml:7, C:\Games\KR\runner\Temp\StagingArea\android-libraries\AN_Res\AndroidManifest.xml:5] Trying to merge incompatible /manifest/application/activity[@name=com.unity3d.player.UnityPlayerNativeActivity] element:
    <activity
    -- @android:configChanges="keyboardHidden|orientation|screenSize"
    -- @android:label="@String/app_name"
    -- @android:name="com.unity3d.player.UnityPlayerNativeActivity">
    <activity
    ++ @android:label="@String/app_name"
    ++ @android:name="com.unity3d.player.UnityPlayerNativeActivity">
    ++ <intent-filter>
    ]
    stdout[
    Warning: [Temp\StagingArea\AndroidManifest-main.xml:1, C:\Games\KR\runner\Temp\StagingArea\android-libraries\AN_Res\AndroidManifest.xml:2] /manifest/supports-screens defined in library, missing from main manifest:
    <supports-screens>
    @android:anyDensity = true
    @android:largeScreens = true
    @android:normalScreens = true
    @android:smallScreens = true
    @android:xlargeScreens = true
    ]
     
  45. churi24

    churi24

    Joined:
    Sep 17, 2013
    Posts:
    65
    Hi Ricardo Iorio :p when you open it on a blank project it autocomplete the project settings. Ctrl+Shift+B, go to Player Settings, and take a look at Product Name. Maybe in your project on your bundle identifier is still referencing to com.Company.ProductName.
     
  46. Dr. Argento

    Dr. Argento

    Joined:
    Jan 29, 2015
    Posts:
    23
    @churi24 Hahaha :p .. Mmm my settings are OK (i double check), the problem is here, take a look:



    For some reason unity does not recognized, and i don't know why.

    @AlexRay
     
    Last edited: Dec 12, 2015
  47. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    Let's try to clarify this case.
    That's quite strange behaviour you get in your project.
    Did you test InAppBillingSample scene?
    Please, test this scene if not and check Product Purchased event callback.

    If any issues will take place or Product Purchased callback does not work for you even in Billing Sample scene - please, feel free to contact Stan's Assets Support Team via support@stansassets.com

    Best regards,
    Alex
     
  48. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    You get Manifest Merge error in your project.

    Please. contact Stan's Assets Support Team for assistance.
    Provide all the manifests you have in your project.
    Error full description will be useful also.
    You will get your project fixed in a short time.

    Cheers!
     
  49. AlexRay

    AlexRay

    Joined:
    Jul 9, 2014
    Posts:
    993
    Hello,
    This issue related to your project settings.
    So, you get everything work well in a case of a brand new project.
    That's definitely related to your settings.

    Do you use Unity 5.3.0f4 version?
    I have the same - no issue exists.

    Best regards,
    Alex
     
  50. Dr. Argento

    Dr. Argento

    Joined:
    Jan 29, 2015
    Posts:
    23
    Yap, i'm using Unity 5.3.0f4.. Only happen with my project, but nevermind, i'll see how to solve the problem.