Shruti
Shruti

Reputation: 285

How to setup libGDX project only for Android & iOS?

i have developed some applications on android.But now i want to learn game development in Android & iOS with libGDX. I want to only develop for Android & iPhone.I do not want a desktop project. All tutorials tell me to first create desktop project than write code in main project & than run as Android application. But i want to write code in android project using both android & libGDX features. is this possible ? if yes than how ?

Upvotes: 2

Views: 1847

Answers (1)

nEx.Software
nEx.Software

Reputation: 6862

In order for you to multi-target with LibGDX, you need to use the core project for shared code, and the starter project for each platform you are targeting (the desktop target is not required if you don't intend to do desktop). If you want to use platform specific code, typically that would be done through an interface (see https://code.google.com/p/libgdx/wiki/ApplicationPlatformSpecific).

If you want to only target a single platform and not use a shared project, you can can create a single project for that platform then add the appropriate jars and other resources. I think this makes more sense for Desktop only or Android only as the iOS stuff is less straightforward to set up.

Upvotes: 4

Related Questions