CharacterControl There is no “setMaxSlope(float)” How steep the slopes and steps are that the character can climb without considering them an obstacle. Higher obstacles need to be jumped. Vertical height in world units.
My understanding is that SetPhysicsLocation is used to adjust the origin position Maybe I misunderstood
You can see that neither CharacterControl nor ghostControl has properly wrapped the model
I need to adjust the CharacterControl and ghostControl origin positions
Learn about the restrictions on ghosts from Wiki Workaround: + Please use PhysicsSpace.sweepTest() instead, or kinematic physics objects with collision listeners.
Prepare to try this scenario
Either create a new Node and attach your character to that node and offset it inside the node then add CharacterControl to that node.
Node node = new Node();
character.move(0, -1, 0);
or, instead use a CompoundCollisionShape and add your collision shape into it with offset:
something like this:
CompoundCollisionShape compoundShape = new CompoundCollisionShape();
compoundShape.addChildShape(new CapsuleCollisionShape(), new Vector3f(0, -1, 0));
CharacterControl control = new CharacterControl(compoundShape, slope);