Search Unity

[Released] Android Native Plugin

Discussion in 'Assets and Asset Store' started by stanislav-osipov, Sep 20, 2013.

  1. jjevol

    jjevol

    Joined:
    Oct 28, 2014
    Posts:
    5
    I am a Korean developer.
    Please note that do not speak English.

    I want to change the encoding in the receiving part GCM do not know what to do.
    There are currently encoded in the Korean writable broken.
    I have to be encoded in UTF-8 when you want GCM

    But did not find the part that you can change.
    Please help.
     
  2. 1HpLeft

    1HpLeft

    Joined:
    Dec 13, 2012
    Posts:
    81
    Hello , when do you think it's going to be fix (the ads & achievements problem) , it's the last piece of my game ^^.
     
  3. Kilosoft

    Kilosoft

    Joined:
    Aug 16, 2014
    Posts:
    1
    Hi! I want to deal with the plugin!
    I write the code:

    void Start () {
    GooglePlayConnection.instance.connect ();
    }

    In debug I see such:
    [11/14/2014 17:46:19.656] [INFO] Play Serice Connection State -> STATE_CONNECTING
    [11/14/2014 17:46:29.605] [INFO] Play Serice Connection State -> STATE_DISCONNECTED

    What am I doing wrong? Where it is necessary to enter the application id?

    //////////////////////////////
    По русски:
    Привет, разбираюсь с плагином.
    Пишу код:

    void Start () {
    GooglePlayConnection.instance.connect ();
    }

    В отладке вижу:
    [11/14/2014 17:46:19.656] [INFO] Play Serice Connection State -> STATE_CONNECTING
    [11/14/2014 17:46:29.605] [INFO] Play Serice Connection State -> STATE_DISCONNECTED

    Что я делаю не так? Куда надо ввести id приложения?
     
  4. EmeralLotus

    EmeralLotus

    Joined:
    Aug 10, 2012
    Posts:
    1,462
    Is it possible to use this plugin to send SMS, send or receive phone calls.
     
  5. H3core

    H3core

    Joined:
    Dec 28, 2012
    Posts:
    7
    Hi , im getting this error as it try to build project i looked around online and couldnt find similar situation error is:

    any ideas?

    Thnx
     
  6. DarkArts-Studios

    DarkArts-Studios

    Joined:
    May 2, 2013
    Posts:
    389
    Nevermind I solved my issue, I'd miss-copied my app_id into res/values

    @lacost : Hi, I'm hoping you can help me.

    I'm attempting to use this for the first time and no matter what I've tried I get back "Cancelled" on connection attempts.

    My callback to ActionConnectionResultReceived signs in and behaves as it should but I always get a failure inside " result.code.ToString() " as "CANCELED".

    Has anyone else experienced this?

    Thanks.

    [EDIT] I get the same result attempting to connect using the example scene(s).
     
    Last edited: Nov 15, 2014
  7. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    The ads bug will be fixed with the update. The new version will be live by Monday. About achievements. well I think you dod something wrong with the settings, please send the full log to the stans.assets@gmail.com


    The receiving part is inside native java code, under the GcmBroadcastReceiver class. You might find helpful this article:
    https://unionassets.com/android-native-plugin/how-to-compile-android-native-jar-libs-107

    He Kilosoft, I believe I already answered you in the PM.

    Hello, this is know issue, here is article you need:
    https://unionassets.com/android-native-plugin/i-am-getting-build-error-106

    Cheers!
     
  8. jjevol

    jjevol

    Joined:
    Oct 28, 2014
    Posts:
    5
    Were able to solve the previous problem, thanks.
    Then another problem occurred

    "NoClassDefFoundError GCMRgisterDevice: com.google.android.gms.R $ string"

    This problem occurs in GalaxyNote1. In other devices with no problem.
     
  9. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    is play service lib enable in the plugin settings?
     
  10. H3core

    H3core

    Joined:
    Dec 28, 2012
    Posts:
    7
    Thnx for the reply but i already have have SE I'm running on Mac OSX its 64 bit java is what i have.

    1) should i remove and install 32 bit java instead. I also noticed on the oracle site that there is java for mobile but i didn't find an OSX version only windows.

    2) I actually need the Facebook part, unless you mean the FB SDK that comes from FB then i can remove that.

    what do you suggest

    Thnx

    Cheers,
     
  11. jjevol

    jjevol

    Joined:
    Oct 28, 2014
    Posts:
    5
    Yes. enable in the plugin settings

    Since the problem is caused by creating a new project may be executed after the plugin installation
    The same problem occurred.

    This problem occurs in GalaxyNote1.
    other devices with no problem.(GalaxyNote2, GalaxyNote3, GalaxyNote4)

    An error occurs in the "AnUtility.checkPlayServices ()".

    The OS version is 4.1.2.

    But I wonder whether I need to check the play service to the GCM
     
    Last edited: Nov 17, 2014
  12. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    707
    Any news as to whether or not this works in Android 5.0? I was using a different asset for Google Play Games Services (which has been abandoned by the author) and it makes my games crash when running on Android 5.0.

    EDIT: I've made a build using Android Native on my own device running Android 5.0 and it seems to work. Now to finish swapping out all the calls to my old asset to Android Native. Thanks!
     
    Last edited: Nov 18, 2014
  13. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    707
    Hi @lacost / Stan,

    Your documentation could use some work.

    First, a relatively minor gripe: You have a lot of typos throughout your documentation, your Asset Store page listing, and even your code. I understand that English probably isn't your first language, so spelling can be difficult, and spell-check isn't very helpful when dealing with code and function names. But you really ought to get some help if you need it to reduce the number of typos throughout your documentation, asset store listing, and code. Typos just make things look unprofessional and may be losing you customers! I know I would have bought your Android Native plugin months ago when I first discovered it had it not been for all the spelling errors I saw. It might be a good idea to make a public Google Doc (or similar) that allows others to make comments, and get the help of others to point out mistakes and corrections to greatly improve the quality of the documentation.

    Here are a few of the mistakes I've found in the short time I've been looking through your code:

    Tocken => Token
    Loaeded or Loeaded => Loaded
    Achivment => Achievement
    Retrive => Retrieve
    Avaliable => Available

    Now on to more important problems with your documentation:

    Yes, you tell me what enums are available, but you don't tell me what they mean or what they're for. For example:

    Code (csharp):
    1. //GPConnectionState class
    2. enum {
    3.     STATE_UNCONFIGURED,
    4.     STATE_DISCONNECTED,
    5.     STATE_CONNECTING,
    6.     STATE_CONNECTED
    7. }
    OK, so those are mostly self explanatory. But what does UNCONFIGURED mean? Does that mean the device has never before connected to GPServices?

    I want to check to see if my player has connected to GPServices in the past, and if so, connect them immediately when the game starts up. But I don't want to connect them automatically if they haven't signed in before. How can I detect that? I also want my players to be able to disconnect from GPServices permanently so that my app doesn't try to connect again when it starts up. But I'm not sure how to detect that. Sure, I can disconnect, but then how do I know the difference between the player manually disconnecting and my app just starting up and therefore hasn't connected yet?

    I'm also confused on how to unlock an achievement. Reveal and Increment are easy to understand. But how do I unlock? Is that what "reportAchievement()" is for? If so, why is it named reportAchievement? I don't want to report an achievement, I want to unlock an achievement! Your other code uses the word "unlocked" (such as in the STATUS_ACHIEVEMENT_UNLOCKED enum value), so you should be consistent in your code.

    Regardless of what the function is called, the documentation should say what reportAchievement does. Right now it just says "Trigger achievement report request, ACHIEVEMENT_UPDATED event will be fired on complete" but I have no idea what an "achievement report request" is, so this isn't helpful.

    I'm also confused about what GetAchievement() does. It says it gets the achievement board, but what is an achievement board?

    Another thing that's confusing is that some of your functions start with a capitalized letter (such as GetAchievement) and others start with a lowercase letter (such as reportAchievement). Again, you should be consistent in your code.

    All that said, I want to say thanks for what appears to be an amazing and incredibly full-featured asset! I look forward to learning how to use it more effectively.
     
  14. CoredumpLab

    CoredumpLab

    Joined:
    Mar 11, 2014
    Posts:
    14
    Hi Stan,

    FYI
    I have updated the plugin to 5.0 but the version is 4.92 in Unity editor.
    I have tried upgrade with the upgrade button and removing the all plugin files (include andro's jars & files) and import it all also, but version is still 4.92.

    Nevertheless, Thank you the version 5.0 !
    I will test the new save game functionalities.
     
  15. 1HpLeft

    1HpLeft

    Joined:
    Dec 13, 2012
    Posts:
    81
    Thanks it's fix all my problem ( ads & achievements) .

    I must agree with Deeozan the typo doesn't make your code look pro ( even if it is ^^ and I thanks you for the plugin )
     
  16. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    Yep try to install 32bit Java, This is issue of the your pc environment. Unfortunately I can not fix it because problem related with unity Official FB SDK. if you need only posting feel free to remove it, and use native device API. You can get more info here:
    https://unionassets.com/mobile-social-plugin/coding-guidelines-134
    But problem is related to java, switch it to 32-bit version and you good to use FB oAuth API.


    Well yes, because GCM is part of Play Services API. But issue you have described is super weird, please let me know if it will steel priests with new version. And if it is, I would like to set up a meeting with you if you ok with this.


    I am glad to heat that you already have tested it with Android 5.0, But you can be sure that I am not going to abandon my asset and if you guys will have any issue regarding new Unity or new Android version, you can except it to be fixed ASAP.


    Thanks for the report just got it fixed.
     
  17. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    707
    I know I left some critical feedback on your code/site/documentation, but I also asked several questions that you haven't addressed.

    Will you please answer them? I'd greatly appreciate it.

    EDIT: I found the toolbar links to more thorough documentation. I thought that all the documentation was in the Extensions/AllDocumentation folder, in the 3 PDF files contained there. I'm reading the documentation on your site and it seems to answer all of my questions.

    May I recommend that you update the PDF to include information about the documentation that can be found in the Window -> Android Native -> Documentation dropdown?

    It would also be nice if this extra documentation was available offline in the rare case where your customers need to refer to the documentation but don't have an internet connection.

    Thanks again for this powerful asset. I know I sound really critical but it's because I can tell that Android Native is very fully featured and powerful, and I just want to make it easier for people to see that and avoid frustrations with it. I've already converted one of my (simpler) games over to using Android Native, and have just started converting a more complicated one. It's looking like once I find the right documentation, it will be relatively easy to make the switch. So thanks again!
     
    Last edited: Nov 18, 2014
  18. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    I answered hours before but Unity frume was down adn seem like my answer is gone, so i need to type it again, any way....

    Unfortunately yes, do my best, but currently I can not affront somebody who will do constant spelling check for me.

    I would love to get any help ctually


    On it thanks


    I was using public google doc but plugin is growing and google simply can not handle so much info, it works and loads too slow. So I have ti migrated to the another documentation representation, and union assets, seems like a good place for it :)


    Added explanation
    https://unionassets.com/android-native-plugin/sign-in-132

    I just added answers to his guide:
    https://unionassets.com/android-native-plugin/sign-in-132


    yep you right I will change reportAchievement to unlockAchievement

    This article is describes the way to use tis method:
    https://unionassets.com/android-native-plugin/achievements-139

    You right, I was going to fix the methods naming in future but I guess it's time :)


    I am really appreciate critics, only with customers feedback I can make good products. So thanks that you spended time and did such big feedback.

    Cheers!
     
  19. Deleted User

    Deleted User

    Guest

    I've got problem with admob. I use latest version of your plugin but clicks not count on admob site? Any help?
     
  20. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    Well the clicks my be counted with the delay, just make sure you use your correct units id. My example scene use my my unit's id's.
     
  21. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    707
    Thanks for your quick response and your answers to my questions.

    Do you have any suggestions/preferences on how someone could provide feedback about this? Making a post here about everything seems like it would take a lot of effort and be a distraction from people looking for help with using your asset.

    This is why I suggested something like a Google Doc. You can provide a link that others can click to view the documentation and make comments inline.

    I use something similar with the cInput documentation. Google Docs has served me well for over 2 years in that regard. But if that doesn't work for you then you should come up with some other means of collaboration (wiki? issue tracker?) so that these things can be corrected.

    Thanks again for everything!
     
  22. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    I had google doc, but it's too bug and heavy
    https://docs.google.com/document/d/1px0BVXcZqgrW99OQV4bM7q1rD5NYaCYTxXnn4eS4ytY/edit

    So I migrated to the Union Assets:
    https://unionassets.com/android-native-plugin/manual

    And actually this guys in the early development stage, but that promises to implement issue tracker and "report issue" button for etch article.

    So far if you wiling to help you can just send me e-mail with fixed, or just copy / paste to google doc and send fixed version to me, by using support e-mail or PM on this forum.

    And thanks for your participation, it's always good to know that customer care about how product will grow and evolve.
     
  23. XCO

    XCO

    Joined:
    Nov 17, 2012
    Posts:
    380
    Hello Stan: I get an error when I use your assest...


    Failed to compile resources with the following parameters:
    -bootclasspath "/Users/XCOGAMES/Desktop/SDK_FOLDER/adt-bundle-mac-x86_64-20140702/sdk/platforms/android-21/android.jar" -d "/Users/XCOGAMES/Documents/UNITY PROJECTS/Droid_Checker_01/Temp/StagingArea/bin/classes" -source 1.6 -target 1.6 -encoding UTF-8 "com/facebook/android/Manifest.java" "com/facebook/android/R.java" "com/xcogames/RKZS/Manifest.java" "com/xcogames/RKZS/R.java"
    warning: java/lang/Object.class(java/lang:Object.class): major version 51 is newer than 50, the highest major version supported by this compiler.
    It is recommended that the compiler be upgraded.
    warning: java/lang/String.class(java/lang:String.class): major version 51 is newer than 50, the highest major version supported by this compiler.
    It is recommended that the compiler be upgraded.
    2 warnings

    UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()

    Do you know if I should do something ? Sorry Android is so new to me :-O
     
  24. CoredumpLab

    CoredumpLab

    Joined:
    Mar 11, 2014
    Posts:
    14
    Hi Stan,

    Is it possible to implement the "Games.Snapshots.commitAndClose()" for Game Play Service feature ?
    It would provides the more flexible code for developers.
    (I can resolve it with GP_SnapshotConflict and some magic maybe, but above method it could be more elegant)
    Ups ! I see now ! You use it in the writeSnapshot method !!! Sorry !
    Is there possible to change & wired out this method scope : private String writeSnapshot()
    for call it from Unity C# ??
    ?

    I reviewed the source and I resolved my issue now !
    If I save the previously opened save game (which is modified by code) with the same Title then it will be overwritten. That is what I want.


    FYI
    I think, there is a problem in the example code in Loading avaliable saves section in documentation.
    (not paying too much attention for typos :) )
    (https://unionassets.com/android-native-plugin/saved-games-142)
    I think this is the correct :
    Thank you !
    Coredump
     
    Last edited: Nov 21, 2014
  25. escic

    escic

    Joined:
    Aug 6, 2013
    Posts:
    42
    How can i fixes this error then unity build apk? it both happen on my pc and mac, and i had installed the java on this page http://www.oracle.com/technetwork/java/javase/downloads/index.html and turn off Facebook plug-in.

    UnityEngine.UnityException: Unable to find suitable jdk installation. Please make sure you have a suitable jdk installation. Android development requires at least JDK 6 (1.6). The latest JDK can be obtained from the Oracle
    http://www.oracle.com/technetwork/java/javase/downloads/index.html
    at UnityEditor.Android.AndroidFileLocator.LocateJDKHome () [0x00000] in <filename unknown>:0
    at UnityEditor.Android.AndroidFileLocator.LocateJDKbin () [0x00000] in <filename unknown>:0
    at UnityEditor.Android.AndroidSDKTools.RunCommand (System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) [0x00000] in <filename unknown>:0
    at UnityEditor.Android.AndroidSDKTools.RunCommand (System.String[] sdkToolCommand, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) [0x00000] in <filename unknown>:0
    at UnityEditor.Android.AndroidSDKTools.RunCommand (System.String[] sdkToolCommand, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) [0x00000] in <filename unknown>:0
    at UnityEditor.Android.AndroidSDKTools..ctor (System.String sdkRoot) [0x00000] in <filename unknown>:0
    at UnityEditor.Android.AndroidSDKTools.GetInstance () [0x00000] in <filename unknown>:0
    at UnityEditor.Android.AndroidKeystoreWindow.GetAvailableKeys (System.String keystore, System.String storepass) [0x00000] in <filename unknown>:0
    UnityEditor.DockArea:OnGUI()
     
  26. IndieFist

    IndieFist

    Joined:
    Jul 18, 2013
    Posts:
    520
    I`m reading all documentation and i cannot find why i get disconnect automatically when i try to use play services.
    I see the window of my game, i grant permissions and later dissapears.
    Using and example escene from plugin same process... connecting and later play service: connection result: canceled.
     
  27. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    707
    I'm getting some errors when trying to save using the Google Drive Game Saves. I don't understand what I'm doing wrong. It worked once. But after that first time my app crashes any time I try to save.

    This is the code I'm using to try to save:

    Code (csharp):
    1. GooglePlaySavedGmaesManager.instance.CreateNewSpanShot("BlasteroidsData", "Blasteroids progress and stats.", screenshot, gameData.ToByteArray());
    Do I understand this correctly?
    The first string ("BlasteroidsData") is a name for the save. It can be anything I want, and the player never sees this?
    The second string ("Blasteroids progress and stats.") is a description of the snapshot which the player will see.
    Third parameter is a Texture2D as a screenshot (apparently my images are too large, according to the logcat).
    Fourth parameter is the save data as a byte array.

    (I'm a little confused about this because according to the Save Game Metadata documentation I should also be able to supply a "total time spend playing" variable, but that doesn't seem to be included in your snapshot functions)

    Here is the data contained in the logcat:

    Any tips or ideas of what could be wrong?

    (P.S. GooglePlaySavedGmaesManager should be spelled GooglePlaySavedGamesManager and there are several functions/properties/etc. where you spelled Snapshot as SpanShot.)
     
  28. escic

    escic

    Joined:
    Aug 6, 2013
    Posts:
    42
    Hi, i find your plugin is requires Unity 4.6.0 or higher. But 4.6.0 still in Beta. And I still in4.5, I don't know... may be this make the errors. Anyway thanks for cool plugin.
     
  29. CoredumpLab

    CoredumpLab

    Joined:
    Mar 11, 2014
    Posts:
    14
    Hi Deozaan,

    I had the same issue, the solution was remove the app from device (uninstall) and reinstall it.

    Coredump
     
    Last edited: Nov 21, 2014
  30. Tripwire

    Tripwire

    Joined:
    Oct 12, 2010
    Posts:
    442
    I would like to know this too! Can I use your plugin in Unity3D 4.5.5 without any problems?
     
  31. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    According to the log you just need to update the Android SDK using SDK manager.


    You right, thanks for the tip, fixed :)


    Well it's not really related to the plugin.
    But error says that you have problems with the JDK installation, I would suggest to follow this guide:
    https://developer.android.com/sdk/installing/index.html


    You was disconnect due to some error (do not know which exactly without seeing the log). The error is related to the setting in the google play console, plugins settings, or Unity building setting, you can get more info about the error by ready device log output.
    If you steel need help, feel free to send your issue description with attached log ti the stans.assets@gmail.com


    Thanks, will fix it in the upcoming update.

    About snapshot issue I will analyse it tomorrow and let you know.


    My bad will fix it right now, The plugin requirements is Unity 4.0 or higher.


    Sure you can, I just used 4.6 for submitting by mistake, I will resubmit it with 4.3.0 right now.
     
  32. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    707
    This worked for me, too. Saving now seems to work as intended. Thank you @CoredumpLab!

    I hope I don't have to tell all players who play my game that when they auto-update from Google Play, they have to uninstall and reinstall to keep it from crashing.


    @lacost: I've also been seeing this message in the logcat a lot. But I'm not sure if it's a problem with Android Native or not:

     
  33. CoredumpLab

    CoredumpLab

    Joined:
    Mar 11, 2014
    Posts:
    14
    I'm happy that helped to you also, I have spent a couple of hours before realized it. :)
    I think (and I hope also) there is no need remove/reinstall the app at every update.
     
  34. Deozaan

    Deozaan

    Joined:
    Oct 27, 2010
    Posts:
    707
    Since I reinstalled the first time, I haven't had problems. So I don't expect to have to reinstall for each update. But requiring my players to uninstall and re-install for even one update is too many.

    Some players won't read or see the instructions/warning and so it will just crash, and leave 1 star reviews because they think it's crap and doesn't work. )c:
     
  35. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    Fixed, thanks for the reort


    You right, there was and issue in the plugin implementation, which is already fixed, and will be available with version 5.1


    Good point.
    CreateNewSnapshot - PlayedTime param added
    GP_SnapshotMeta - TotalPlayedTime filed added


    Cheers!
     
  36. EmeralLotus

    EmeralLotus

    Joined:
    Aug 10, 2012
    Posts:
    1,462
    Hi Stan,

    I asked this question before "Is it possible to use this plugin to send SMS, send or receive phone calls". Android supports SMS sending and receiving whereas IOS doesn't. Wondering if this kind of functionality can be exposed with your plugin.

    Cheers.
     
  37. srenshaw

    srenshaw

    Joined:
    Feb 12, 2014
    Posts:
    14
    I'm using playerprefs to save 3 bools and a score float in my Android App, which should have minimal storage requirements. However, when I look at the data storage on my test devices, both the Data and Cache figures increase each time I run the App. I'm guessing that the cache is increasing due to the Ads (not sure what else it could be), but I didn't expect the Data figure to increase. It's currently at 5mb and rising - will this be related to the 'Internal data leak within a DataBuffer object detected!' problem?
     
  38. Imoox Studio

    Imoox Studio

    Joined:
    Nov 24, 2014
    Posts:
    5
    Hey Stan, where can we report bugs we encountered with the plugin?

    If this is the right place then here is the issue I had:

    I downloaded the whole package and after setting up all the Facebook details (and testing them to see if they worked correctly, which they did) I did some use cases testing:

    I loaded up the FacebookExample scene, (located in Assets/Extensions/AndroidNative/xExample/Scenes/Social/), and loaded the app on a Nexus 5 phone.

    When you attempt to share something on Facebook by clicking on the "Post With Auth Check" button, it loads up the Facebook login page as it should. If you click the "X" icon on the top-left corner to close the Facebook pop-up and then attempt to click on the "Post With Auth Check" button one more time, the app will force-close.

    (Again, this was tested on a Nexus 5 running Android 5.0 without the Facebook app installed on it, but I also had the same issue on a Samsung Galaxy Note 10.1 tablet running Android 4.4.2).

    Has this happened to someone else?

    Regards.

    Daniel
     
  39. MrTiger

    MrTiger

    Joined:
    Jan 9, 2014
    Posts:
    29
    How to test your PlayServiceExample Scene in android emulator ? coz i tried with AVD manager "Android platform Ver 4.4.2 and also tried it in real device but i keep getting a message in the bottom saying that "ConnectionResul: CANCELED" and i am using Unity 4.6 RC2 ..
    this is what i changed in the ids.xml file
    and this is what i changed in your script
    plz let me know did i make any mistake or do i have to change any thing else ....(i already setup my play service in my Google Dev Page )
     
  40. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    Hello, there is no such feature currently, and honestly I am not going to add this in nearest future, since it's not very common feature for the game development.


    Not sure. Plugin does not store any data in playerprefs or android storage ( will couple strings tops). DataBuffer leak is already fixed. So will see if it solves the issue, but I am pretty sure it nothing to do with the plugin.
    But some of google APIs may use caching, which I can not control.


    best way is to use stans.assets@gmail.com

    Thx for detailed report I will defiantly check this.


    First of all it's recommend to use the real device.
    ConnectionResul: CANCELED - means that user has cancelled sight in flow, or you have some issues with the app settings. You can find out is there is othe issues by reading the device log, Or just send youe device log with the problem description to the stans.assets@gmail.com
     
  41. jarga

    jarga

    Joined:
    Jul 23, 2014
    Posts:
    4
    Hi Stan,

    Please tell me how to get response when a banner open and shown on the screen.

    I tried this
    =========================================

    void Start()
    {
    AndroidAdMobController.instance.addEventListener(GoogleMobileAdEvents.ON_BANNER_AD_OPENED, ON_BANNER_AD_OPENED);

    }

    void ON_BANNER_AD_OPENED()
    {
    text = "BANNER_AD_OPENED";
    }
    =========================================
    It doesn't work.

    Then I tried this
    =========================================
    private void CreateBannerCustomPos() {
    banner1 = AndroidAdMobController.instance.CreateAdBanner(300, 100, GADBannerSize.BANNER);
    banner1.OnOpenedAction += ON_BANNER_AD_OPENED;
    }

    void ON_BANNER_AD_OPENED(GoogleMobileAdBanner banner)
    {
    text = "BANNER_AD_OPENED";
    }
    =========================================
    It still no work.

    I HAVE MAIL TO YOU 3 TIMES.
    GOT REPLY LIKE

    "Please try my plugin with default code, without your own. If you get some errors send to me log of logcat please."

    OR

    "You needed add listeners on Banner."

    OR

    "Look at my example class - AndroidGoogleAdsExample."

    I DID TEST YOUR EXAMPLE AND STILL CANNOT FIND THE ANSWER.
    AND I SEND YOU MY CODE, JUST MODIFIED FROM YOUR AndroidGoogleAdsExample.cs.
    I JUST WANT YOU GIVE ME A SAMPLE SHOW ME HOW TO DO IT. OR TELL WHAT'S WRONG IN MY CODE.

    IS THAT HARD???
    IS THAT SO HARD??????????????
     
  42. BrendanKZN

    BrendanKZN

    Joined:
    Jun 22, 2011
    Posts:
    157
    Hi Stan, thank you for a great asset!
    I'm having a small issue at the moment, not sure if it's the device causing it. When I call the LoadInterstitialAd I have to wait a bit then call LoadInterstitialAd again before I can call ShowInterstitialAd. I built a new project and did a clean import and it does it on your GoogleAdExample scene, you have to press the Load Interstitial Ad button twice before the Show button is enabled. Really odd? Anyone's opinion would be much appreciated.
     
  43. Darkttd

    Darkttd

    Joined:
    Sep 24, 2014
    Posts:
    5
    Hello, I have a problem with GCM feature.

    My app send crash signal when receive GCM message.
    next is crash information on receive GCM message.

    Code (CSharp):
    1. FATAL EXCEPTION: IntentService[GcmIntentService]
    2. java.lang.Error: FATAL EXCEPTION [IntentService[GcmIntentService]]
    3. Unity version     : 4.5.5f1
    4. Device model      : samsung SHW-M380W
    5. Device fingerprint: samsung/SHW-M380W/SHW-M380W:4.0.4/IMM76D/UH11:user/release-keys
    6. Caused by: java.lang.NullPointerException: println needs a message
    7.     at android.util.Log.println_native(Native Method)
    8.     at android.util.Log.d(Log.java:138)
    9.     at com.androidnative.gcm.GcmIntentService.sendNotification(GcmIntentService.java:133)
    10.     at com.androidnative.gcm.GcmIntentService.onHandleIntent(GcmIntentService.java:78)
    11.     at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:65)
    12.     at android.os.Handler.dispatchMessage(Handler.java:99)
    13.     at android.os.Looper.loop(Looper.java:137)
    14.     at android.os.HandlerThread.run(HandlerThread.java:60)
    15.  
    GCM worked on Android Native Plugin v4.8 but, latest version didn't work.
    I presume that you missed this feature when split native jar spliced. but if you perfect, please let me know if anything incorrect and how it can be fixed.

    Thank you.
     
  44. Darkttd

    Darkttd

    Joined:
    Sep 24, 2014
    Posts:
    5
    addition information:

    GCM receive is available only when my app is RUNNING.
    when my app is not running, it always crash.

    thanks.
     
    Last edited: Nov 27, 2014
  45. XCO

    XCO

    Joined:
    Nov 17, 2012
    Posts:
    380
    Hello STAN,

    I keep getting this error - Have re-installed my SDK upgraded and did everything "I THINK" I should do.

    But droid is new to me so maybe I am not doing somehting right ?

    "
    Failed to compile resources with the following parameters:
    -bootclasspath "/Users/XCOGAMES/Desktop/adt-bundle-mac-x86_64-20140702/sdk/platforms/android-21/android.jar" -d "/Users/XCOGAMES/Documents/UNITY PROJECTS/Droid_Checker_01/Temp/StagingArea/bin/classes" -source 1.6 -target 1.6 -encoding UTF-8 "com/facebook/android/Manifest.java" "com/facebook/android/R.java" "com/xcogames/RKZS/Manifest.java" "com/xcogames/RKZS/R.java"
    warning: java/lang/Object.class(java/lang:Object.class): major version 51 is newer than 50, the highest major version supported by this compiler.
    It is recommended that the compiler be upgraded.
    warning: java/lang/String.class(java/lang:String.class): major version 51 is newer than 50, the highest major version supported by this compiler.
    It is recommended that the compiler be upgraded.
    2 warnings"

    I keep getting this error, mind you I can publish fine without you API in the project but when It is in I get this every-time, can you be specific when helping me ?

    I am very lost and have tried everything on my own as to not bother you too much, but it's been a week now... :|

    Thanx in advance for any assistance!! Please be specific as what you think I should do, droid is new to me...
     
  46. Tdgs2

    Tdgs2

    Joined:
    Jan 30, 2014
    Posts:
    2
  47. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    Hey jarga. I am sorry that you have a bad experience with the support team. I will talk with the guys, and I will prepare code snippet for you which I will add to the documentation and will send you PM message with the url.


    I will defiantly check this, but can you please share log cat log with me? You can send it to the my personal mail or use PM.

    Hello, thanks for the report I will check this tomorrow morning in the office and you know


    Nope but I working on some network plugin :)


    Well solution is described here;
    https://unionassets.com/android-native-plugin/i-am-getting-build-error-106

    Cheers!
     
    XCO likes this.
  48. stanislav-osipov

    stanislav-osipov

    Joined:
    May 30, 2012
    Posts:
    1,790
    Hey jarga. here is the code snippet for you, let me know if you need any other help

    Code (CSharp):
    1. GoogleMobileAdBanner banner;
    2. banner = AndroidAdMobController.instance.CreateAdBanner(TextAnchor.UpperLeft, GADBannerSize.BANNER);
    3. banner.OnOpenedAction += OnOpenedAction;
    4.  
    5.  
    6. void OnOpenedAction (GoogleMobileAdBanner banner) {
    7.     banner.OnOpenedAction -= OnOpenedAction;
    8.     Debug.Log("Banner was just clicked");
    9. }
    Cheers!
     
  49. jarga

    jarga

    Joined:
    Jul 23, 2014
    Posts:
    4
    Thanks.

    But that seem doesn't work for me.
    I tried this in your AndroidGoogleAdsExample.cs.
    =========================================
    string text = "ggyy";

    void OnGUI()
    {
    GUI.Label(new Rect(10, 10, 500, 100), text);
    }

    private void CreateBannerCustomPos()
    {
    banner1 = AndroidAdMobController.instance.CreateAdBanner(300, 100, GADBannerSize.BANNER);
    banner1.OnOpenedAction += BO;
    }

    void BO(GoogleMobileAdBanner banner)
    {
    banner.OnOpenedAction -= BO;
    text = "BANNER_AD_OPENED";
    }
    =========================================

    I can see the banner shown on screen. But the text is still "ggyy".
    I don't know what's going on.
    Can you test this?
     

    Attached Files:

  50. unitywlp

    unitywlp

    Joined:
    Jan 3, 2014
    Posts:
    146
    do you plan for startapp integration as well

    i need playmaker actions for this