Gradle Build fails with Nifty for Android App

Hi there,

trying to use jMonkeyEngine on AndroidStudio, but it just won’t work. I have two modules: app and desktop. Each has a build.gradle file with dependencies. The desktop module builds fine, but the android module stops with an error:

`

Error:Failed to resolve: lessvoid:nifty-default-controls:1.4.1
Open File
Show in Project Structure dialog
`

build.gradle

`

apply plugin: 'com.android.application'
android {

compileSdkVersion 23
buildToolsVersion "23.0.3"

defaultConfig {
    applicationId "ar.limbusdev.org.arnetrayx"
    minSdkVersion 19
    targetSdkVersion 23
    versionCode 1
    versionName "1.0"
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}

}

`

repositories {
    mavenCentral()
    maven {
        url 'http://updates.jmonkeyengine.org/maven'
    }
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:23.3.0'
compile 'com.android.support:support-v4:23.3.0'
compile 'com.jme3:jme3-android:3.1.+'
compile 'com.jme3:jme3-core:3.1.+'
compile 'com.jme3:jme3-effects:3.1.+'
compile 'com.jme3:jme3-networking:3.1.+'
compile 'com.jme3:jme3-plugins:3.1.+'
compile 'com.jme3:jme3-jogg:3.1.+'
compile 'com.jme3:jme3-terrain:3.1.+'
compile 'com.jme3:jme3-jbullet:3.1.+'
compile 'com.jme3:jme3-niftygui:3.1.+'
}

`

Hope someone knows what to do.

Cheers,
Gem

Should be fixed for 3.1 and 3.2.

Okay, I’ll try again as soon as I can. Thanks

I am also looking to installing JMonkeyEngine on Android Studio but still not able to do so. Somewhere I found the codes below. they should be same but looks different. Since the official site has domain with .org the following could be right one.

compile "org.jmonkeyengine:jme3-android:$jmeVersion"
compile "org.jmonkeyengine:jme3-android-native:$jmeVersion"
compile "org.jmonkeyengine:jme3-core:$jmeVersion"
compile "org.jmonkeyengine:jme3-effects:$jmeVersion"
compile "org.jmonkeyengine:jme3-jogg:$jmeVersion"
compile "org.jmonkeyengine:jme3-plugins:$jmeVersion"

if your code works please tell me too. You can comment to check if your code is right one and remove that error.

 compile 'com.jme3:jme3-niftygui:3.1.+'

I have same problem too, solved dependency problem by writing
compile "org.jmonkeyengine:jme3-niftygui:[3.1,)"
But it gives another error
WARNING: Dependency xpp3:xpp3:1.1.4c is ignored for debug as it may be conflicting with the internal version provided by Android.
How can i solve it?