Search Unity

Android Unity plugin - Class not found exception

Discussion in 'Android' started by Defi, May 14, 2016.

  1. Defi

    Defi

    Joined:
    Jan 2, 2014
    Posts:
    1
    I want to export an android library to Unity, but that Android gives the following error:
    I copied all code that could be relevant below, probably you can skip half of it :p

    My AndroidManifest (I copied the one from my library into Unity) is as follows:
    The dependencies are fairly straightforward and are declared in Gradle:
    On a forum I read Unity needed to have the dependencies copied into Assets/Plugins/Android, although I'm using an aar instead of a jar. So I copied support-v4-23.3.0-sources.jar into Assets/Plugins/Android as well, but play-services-8.4.0.jar not because it's not included in the Android system files. play-services-8.4.0.aar is included, but if I copy that to Unity I get the following error:
    Does anybody have an idea how to solve the ClassNotFoundException?
     
  2. liortal

    liortal

    Joined:
    Oct 17, 2012
    Posts:
    3,562
    Are you sure that the activity class com.joostverbraeken.weargame.MainActivity exists inside your Unity project, compiled into a .jar file, .aar file or an Android library project ?