Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
Adding ads and IAB to an Android Studio project. — Gideros Forum

Adding ads and IAB to an Android Studio project.

simwhisimwhi Member
edited July 2015 in General questions
Hi everyone,

Now that we have Android Studio export support, I was wondering how we add plugins such as ads and IAB to the project.

Is there any documentation/guide for this?

Cheers

Comments

  • ar2rsawseenar2rsawseen Maintainer
    Well, the short version is:
    .jar files should go to app\libs
    .so files should go to respective app\src\main\jniLibs
    And all other .java files go to respective app\src\main\java
    Main activity is in app\src\main\java\com\giderosmobile\android
    And Android manifest is in app\src\main

    Likes: MobAmuse

    +1 -1 (+1 / -0 )Share on Facebook
  • simwhisimwhi Member
    @ar2rsawseen Thanks for the info. I'll give it a try.
  • I've tried and I get "package com.vungle.sdk does not exist". Am I supposed to install the sdk before setting up the ads plugin? I thought the sdks was part of it? Thanks
  • ar2rsawseenar2rsawseen Maintainer
    you need to add vungle jar into libs folder

    you can find it in All Plugins\ads\source\Android\libs
  • I have the "vungle-publisher-1.3.11.jar" in the app/libs folder but

    Error:(9, 22) package com.vungle.sdk does not exist
    Error:(12, 58) package VunglePub does not exist
    Error:(38, 4) cannot find symbol variable VunglePub
    Error:(43, 4) cannot find symbol variable VunglePub
    Error:(52, 3) cannot find symbol variable VunglePub
    Error:(53, 3) cannot find symbol variable VunglePub
    Error:(63, 7) cannot find symbol variable VunglePub
    Error:(65, 14) cannot find symbol class VunglePub
    Error:(71, 7) cannot find symbol variable VunglePub
    Error:(88, 13) cannot find symbol class VunglePub
    Error:(97, 34) cannot find symbol variable VunglePub
    Error:(145, 2) method does not override or implement a method from a supertype
    Error:(155, 2) method does not override or implement a method from a supertype
    Error:(163, 2) method does not override or implement a method from a supertype
    Note: Some input files use unchecked or unsafe operations.
    Note: Recompile with -Xlint:unchecked for details.
    96 warnings
    Error:Execution failed for task ':app:compileDebugJava'.
    > Compilation failed; see the compiler error output for details.
  • ar2rsawseenar2rsawseen Maintainer
    Do you see vungle jar in Android studio?
    if yes, then try right click on it and select add as dependency or something like that
  • The vungle-publisher-1.3.11.jar doesn't show up, but then I don't see the libs folder in android studio, just the contents of the main folder. I tried copying it to the jnlibs folder but then get:

    Error:(9, 22) package com.vungle.sdk does not exist

    The AdsVungle.java file shows a greyed out import:

    import com.vungle.sdk.VunglePub;

    With vunglePub in red. I tried downloading the vungle sdk and put it in the com folder, so the import path matched, but there was no vunglePub java file just a bunch to html files.
  • ar2rsawseenar2rsawseen Maintainer
    there are views you can switch between in android studio like project view and file view, but honestly I don't know how, sometimes I just get it randomly.:)

    but ok then you can do it manually, copy .jar file in libs folder (where gideros.jar is)
    and then inside app folder (and NOT inside root folder) open build.gradle and find
    dependencies {
        compile files('libs/gideros.jar')
    }
    and add compile files('libs/vungle-publisher-1.3.11.jar')
  • Yet again you are a star! Thanks very much. I have ads running on iPhone and android :))
Sign In or Register to comment.