If we have vertical bar and horizontal bar on top of vertical bar. and if we set joint like
horizontalBar should rotate around Y (in blender around Z).
If I push horizontalBar, two edges of horizontalBar is rotatin around Y but edges of horizontalBar are also swinging up and down (Z).
When horizontal bar is rotationg edges are changing Y a little bit. Edges doesn't always have Y=3 like mainAxis have it.
Can I lock hinge so that edges of horizontalBar will not swinging up and down and it will always rotate with same Y=3.
Or I push too hard horizontalBar? Or is there any other/strange problem? Should edges of horizontal bar always rotate with same Y values (in this case Y=always 3)?
var joint = new BABYLON.HingeJoint({
mainPivot: new BABYLON.Vector3(0, 0, 0),
connectedPivot: new BABYLON.Vector3(0, 3, 0),
mainAxis: new BABYLON.Vector3(0, 1, 0),
connectedAxis: new BABYLON.Vector3(0, 1, 0)
});
verticalBar.physicsImpostor.addJoint(horizontalBar.physicsImpostor, joint);