Panda Bullet

Thanks for your answer Thaumaturge… Eventually I solved it with additional CollisionNodes, as the CollisionEntries have a reference to the “from” and “into” NodePaths.

Out of curiosity (maybe this is more of a question to enn0x) is there some limitation in the mechanism that makes supplying a reference to the colliding NodePaths in the raytest results impossible? For now, I cannot get my head around the inner mechanism of collisions in Bullet - if it’s the NodePaths (and not PandaNodes) that have position in the world, then how is it possible that only BulletRigidBodyNodes are added to the BulletWorld? What if, for example, one BulletRigidBodyNode is instanced under several NodePaths? I would understand that some kind of link to the NodePaths is required anyway (correct me if I’m wrong) so then there would be no problem with supplying the colliding NodePaths in the raytest results.
I appreciate all your answers - they will let me understand the system better :slight_smile:

EDIT: Also, one more question - with a BulletNode, I can addShape() with a TransformState translating the shape to a point different than (0,0,0). Any ideas on how to achieve a similar thing with the BulletCharacterController? The controller only takes the BulletShape as a constructor argument but it doesn’t inherit from BulletBody so doesn’t have addShape(). My particular case is: in my game, I want the point (0, 0, 0) of my player NodePath (and all other objects as a matter of fact) to be the point at the “feet” of the object - so that when I set the position of the player to (0, 0, 0) in the render frame of reference, the player will appear standing at x:0 y:0 with their feet on the ground - and not half buried in the ground. For that, all models and physics bodies have to be translated half of the object’s height upwards. I could use a BulletTriangleMeshShape for that, but I was wondering if it is possible to use a BulletCapsuleShape and translate it upwards.