I have a 3D scene with a CharacterBody3D as the root. It has two children; a child CollisionShape3D, and a child CharacterBody3D with its own collision shape.
CharacterBody3D (scene root)
CollisionShape3D (parent collision shape)
CollisionShape3D (child collision shape)
The scene root has a script which calls
PhysicsProcess(). It works fine for the parent and its collision shape, if you hit an obstacle, the parent stops moving. However I would like the parent to stop moving also if the child shape hits an obstacle, and that is not happening.
The child is not being moved manually through scripts, it’s only being taken along with the parent’s movement. I tried changing the child node to a StaticBody3D, but the issue persists. I tried setting the collision layers and masks to be the same for both parent and child and still only the parent collision works.
How can I get the child’s collision to be detected? And the movement to stop/slide even when the child collides, same as the parent? Is there a solution that handles this issue even when the child is instantiated at runtime, through scripts?