I've got problem with adding AndEngine to Google Android Studio IDE.
When i try to run it there are errors like this:
Gradle: error: package org.andengine.engine.camera does not exist
I did the same! I am not sure how does it work exactly. But It seems that Android Studio uses libraries 'just for source' to find the libraries and then IDE uses Gradle like external build tool.
So I have created the libs directory in my project and move *.jar
files there. I have added libraries files (*.jar
) into project dependencies. Than I can use org.andegine
package in my project sources but I had still the error so I have added dependencies also into build.gradle
.
dependencies {
compile 'com.android.support:support-v4:18.0.0'
//compile files('libs/andengine.jar') // for single file
compile fileTree(dir: 'libs', include: '*.jar') // for all files in directory
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With