I am using LibGDX game engine to create 2d games and box2d for physics. How can I check for collisions? Is there sth like box2d for 3d games?
Asked
Active
Viewed 3,617 times
1 Answers
4
is there sth like box2d for 3d games?
Yeah. There is a 3d physics engine in libgdx called Bullet. Written in C C++ it uses a wrapper to be able to communicate with it from java.
To add it to your project, you must add this to your gradle.build file in your project root directory:
Core Dependency:
compile "com.badlogicgames.gdx:gdx-bullet:$gdxVersion"
Desktop Dependency:
compile "com.badlogicgames.gdx:gdx-bullet-platform:$gdxVersion:natives-desktop"
Android Dependency:
compile "com.badlogicgames.gdx:gdx-bullet:$gdxVersion"
natives "com.badlogicgames.gdx:gdx-bullet-platform:$gdxVersion:natives-armeabi"
natives "com.badlogicgames.gdx:gdx-bullet-platform:$gdxVersion:natives-armeabi-v7a"
natives "com.badlogicgames.gdx:gdx-bullet-platform:$gdxVersion:natives-x86"
iOS Dependency:
compile "com.badlogicgames.gdx:gdx-bullet:$gdxVersion"
natives "com.badlogicgames.gdx:gdx-bullet-platform:$gdxVersion:natives-ios"
HTML Dependency: Not compatible!
How to create a game with it is a very broad question. Take a look at this:

Daahrien
- 10,190
- 6
- 39
- 71
-
2@user3693550 you should also take a look at Xoppas blog: http://blog.xoppa.com the latest 2 tutorials cover the bullet library – Robert P Oct 09 '14 at 09:37