- Setting Up
- Creating Projects
- Importing into IDE
- Running and Debugging
Importing a LibGDX project
Importing projects into your IDE should be painless if setup correctly.
- File > Open > ProjectRoot/build.gradle
- Uncheck 'Create separate module per source set'
- Select OK on the 'Import Project from Gradle dialog'
- Import all modules
- Make sure that configure on demand is disabled in your IDEA/AS (File > Settings > Build, Execution, Deployment > Gradle-Android Compiler > Configure on demand)
Once the project has imported you should run a Gradle sync in the IDE to make sure everything is OK. To do this you bring up the Gradle tool window (View > Tool windows > Gradle), and hit the sync button, which is in the top left of the Gradle tool window.
If this succeeds, you are all imported and ready to get developing.
- File > Import > Gradle. As shown below
- Select project root directory, hit finish.
- File > Open Project > Select the project as shown below
- Wait for the project to fully load and configure.