Eamonn
Eamonn

Reputation: 710

IntelliJ can't find any LibGDX packages?

I have just switched to Ubuntu and I've installed IntelliJ IDEA 14 Community Edition. When I imported my existing project, I found that IntelliJ can't seem to find any of the LibGDX dependencies. I installed Gradle beforehand. I've tried using the Gradle wrapper included with the IntelliJ project to and saying ./gradlew --refresh-dependencies, but this doesn't seem to do much of anything. My external TweenEngine packages were loaded just fine. It seems to only be with the LibGDX packages that IntelliJ is having a problem with. I do not wish to have IntelliJ see my project as a Gradle Project, as then it will have to sync. I prefer to do things myself in that regard.

My guess is that Gradle isn't installing the LibGDX dependencies, but I'm not entirely sure why that would be happening. Shouldn't ./gradlew --refresh-dependencies install them? The errors I get are all the same as this one, just with different package names and different line numbers:

Error:(7, 24) java: package com.badlogic.gdx does not exist

The line numbers correlate to my LibGDX class imports, so this is what leads me to believe that Gradle is not installing the dependencies.

When I imported the project, I selected the build.gradle file. I have the local.properties file pointing to a valid Android SDK.

If you want a specific look at the project and would like more detail than I have provided, feel free to check out the source code: http://bitbucket.org/Sonic2kk/mr.-ballguy/

What could be causing these errors and how can I correct them?

Upvotes: 1

Views: 1190

Answers (1)

one2three
one2three

Reputation: 1

Try installing the android sdk. If that doesn't work, try reinstalling IntelliJ.

Also, try linking your IntelliJ project to IntelliJ's Gradle plugin.

Upvotes: 2

Related Questions