What should i use - HullCollisionShape or CapsuleCollisionShape?

In my game, my character oftenly would get randomly stuck near places where there is NO object. I’m using CapsuleCollisionShape right now.


CapsuleCollisionShape capsule = new CapsuleCollisionShape(3f,3f);

character = new CharacterControl(capsule, 0.01f);

model = (Node) assetManager.loadModel(“Models/Oto.mesh.xml”);







character.setPhysicsLocation(new Vector3f(100, 100, 100));


Would HullCollisionShape be a better choice for me? If so, then how do I make one? If not, what are some optimal settings for CapsuleCollisionShape? The model I’m using right now is Oto from the tutorials

Are you sure you’re not just forgetting to remove old rigidbodies? Just detaching won’t do.

How should i go on about removing the rigid bodies? Is it from the model itself or the scene?

-.- the same way you add them, via the method on the physicsSpace… Do you even read your own code? ^^

1 Like

:roll: Yeah sorry I’m just still learning.

How would I in code remove it?

:facepalm: http://hub.jmonkeyengine.org/javadoc/com/jme3/bullet/PhysicsSpace.html#remove(java.lang.Object)

There should be a feature that allows your to point to any previous post :smiley:

there is the insert snippet button which did work before, but that doesn’t seem to be functional atm :frowning:

And which RigidBody do i need to get rid of? My Model, the terrain, or the house model?


i looked at the scene view through scenecomposer, and it appears as if an invisible sphere is around my house. That sphere is what I’m running into i think. How do i get rid of that Sphere?

Okay i figured it out. What i was running into was the Sky Box. I just had to shift it above the scene and that fixed the problem :slight_smile: