You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add the pre-created 'localytics-unity-android-4.2.1.unitypackage' from this 'release' folder in this repo to the project
Set the Project 'Package Name' to be 'com.Company.LocalTest'
Edit the android manifest to use my Localytics key
Add basic script to
Inside Unity choose File->Build Settings...
Choose Android Platform and leave 'build system' on Internal (Default)
Select 'Build And Run'
Project is built... App is sent to device
Results:
Application launches and instantly crashes
Seen in log:
AndroidRuntime: Caused by: java.lang.NoSuchMethodError: No direct method <init>(Landroid/content/ContextWrapper;)V in class Lcom/unity3d/player/UnityPlayer; or its super classes (declaration of 'com.unity3d.player.UnityPlayer' appears in /data/app/com.Company.LocalTest/base.apk)
Per instructions in the Github, navigate terminal to extracted folder and execute 'generate_packages.sh'
Note that java build step fails due to 'ant' not being installed by default on system
Also note that most of script may continue to execute without any indication of failure while the fatal error is hidden at the top of the log.
Further note that unity packages thus created do not contain either a complete or operational plugin
Install 'ant' following advice sought via search engine
Navigate terminal to extracted folder and execute 'generate_packages.sh'
Note the java build step still fails with output: BUILD FAILED /Users/USERNAME/Documents/localytics-unity-master/localytics-android/build.xml:90: Cannot find /Users/USERNAME/Library/Android/sdk/tools/ant/build.xml imported from /Users/USERNAME/Documents/localytics-unity-master/localytics-android/build.xml
Note that, even if the unity package build commands independently execute without error, the .unitypackage files generated will now not contain either the 'LocalyticsApplication' or 'LocalyticsUnityPlayerActivity' classes needed for correct operation with the supplied AndroidManifest.xml.
Results:
Apps created and installed using packages built with this procedure will crash on launch as well, but the errors visible on the Android device will be something about the missing classes 'LocalyticsApplication' or 'LocalyticsUnityPlayerActivity' referenced from the AndroidManifest.xml
The text was updated successfully, but these errors were encountered:
@BenVanCitters First off sorry for the delayed response here. Do you mind opening a support ticket with our support team ([email protected]) if this issue persists?
Hi @Mriegel ,
I fixed the problems I was experiencing in pull request #11"Unity 2017.3 + Android Studio". This pull request was a long time in the making and addresses pipeline issues that are present in the current repository as well as eliminating the problems in the built artifacts. Please review and merge this pull request to ensure current and future stability of your Unity plugin.
I did reach out to the support team. Ultimately, after several weeks of exchange, they were unable to to provide assistance to my team or our client in fixing our crashes.
I am having an extremely difficult time getting this plugin to work for Android.
'Fresh Download' Steps :
Results:
Seen in log:
AndroidRuntime: Caused by: java.lang.NoSuchMethodError: No direct method <init>(Landroid/content/ContextWrapper;)V in class Lcom/unity3d/player/UnityPlayer; or its super classes (declaration of 'com.unity3d.player.UnityPlayer' appears in /data/app/com.Company.LocalTest/base.apk)
'Build Fresh' Steps
BUILD FAILED /Users/USERNAME/Documents/localytics-unity-master/localytics-android/build.xml:90: Cannot find /Users/USERNAME/Library/Android/sdk/tools/ant/build.xml imported from /Users/USERNAME/Documents/localytics-unity-master/localytics-android/build.xml
Results:
The text was updated successfully, but these errors were encountered: