Creating your first libGDX project with Android Studio 1.1.0
This is a quick 'tutorial' on how to get started with libGDX with Android Studio 1.1.0.
Unfortunately while libGDX can be used with Android Studio 1.x, documentation regarding it is sparse.
I'll assume that you have Android Studio 1.1.0 (1.x generally) installed and properly running.
If you haven't already, download libgdx from the official site. The file name should be gdx-setup.jar, and will be run whenever you need to create a new project.
Start gdx-setup.jar and complete the Name, Package, Game class, and Destination as you wish.
For Android Studio 1.x the SDK is located in %localappdata%\Android\sdk
and for beta versions was located in the Android Studio program files directory.
Sadly these values aren't tracked across runs of the jar, and will therefore need to be entered every time you run the tool.
Go ahead and Generate the project and after a short time you'll have a project created.
At the time of this writing you'll be prompted twice regarding different versions.
The first time will be the following:
You have a more recent version of android build tools than the recommended.
Do you want to use this version?
The second time is the following:
You have a more recent Android API than the recommended.
Do you want to use this version?
Select Yes for both options.
Once the tool has finished switch over to Android Studio and select Import Project (Eclipse ADT, Gradle, etc.) from the menu. Then browse to the directory created by the jar (Destination) and open the build.gradle
file.
After some time you should be able to test a deployment of the Android version as you normally would. You may also be interested in running your project as a Desktop application.
Search
Links of Note
Support This Site
If my blog was helpful to you, then please consider visiting my Amazon Wishlist.