For my game I'd like to create another project that extends the functionality of libGDX and since it will be an independent project it could be easily reusable. How can I achieve this in Eclipse IDE? Do I have to use any building tools like Ant or Maven? I'd prefer not using them but I also don't want that the libgdx.jar file to get in the final jar twice. Do I have to create a full libGDX project (with gdx-setup-ui) for the extension project or is it enough to create a simpe Java Project and add the libGDX library?


1 Answer 1


I found the answer in Aurelien Ribbon's forum: http://www.aurelienribon.com/forum/viewtopic.php?f=7&t=2

This is easy to do:

  1. Create a project for your library (we'll refer to it as the "mylib" project),
  2. Add gdx.jar and tween-engine-api.jar to its build path (put these files in its "libs" folder, which you have to create),
  3. Add your source files to its "src" folder,
  4. Generate the 4 test projects with the ProjectSetup tool (tick the "Universal tween Engine" library),
  5. Add your "mylib" project to the build path of the main test project (check its checkbox to export it [1])

Now you should be able to work on your library in the mylib project, and to directly test it in the desktop/android/html projects.

[1] it is required for the android test project to work since the Android SDK rev17


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .