Dear experts,
I am trying to find a way how to perform action with doors.
Currently I implemented two animations, which do open and close door.
Then I realized the RigidBodyControl applied to the door does not change its position.
Then I found the method setKinematicSpatial, but it also does not work.
Does it just never work with animation or it is me who misses something?
Here is my code:
RigidBodyControl innerDoorPhy = new RigidBodyControl(0f);
innerDoor.addControl(innerDoorPhy);
innerDoorPhy.setSpatial(innerDoor);
// This does not work whenever it is false or true
// innerDoorPhy.setKinematic(true);
innerDoorPhy.setKinematicSpatial(true);
this.getPhysicsSpace().add(innerDoorPhy);
How do you usually implenent it? The door should have 3 states: locked, opened, closed.
Locked shoult not open by click, otherwise it should close if opened or open if closed