Why does the entity that has the dynamic-body component act like the center of mass is at the position of the entity and not at the position of the cannon body?
From my understanding, the center of mass should be somewhere on the geometries of one of the children. It is seen more clearly when the position of the children is farthest from the parent position, but the body created by “dynamic-body” gravitates towards the position of the parent entity and I don’t understand why this behavior happens. Shouldn’t the original position not matter anyway since the entity is dynamic?
<html>
<head>
<script src="https://aframe.io/releases/1.5.0/aframe.js"></script>
<script src="https://cdn.jsdelivr.net/gh/c-frame/[email protected]/dist/aframe-physics-system.js"></script>
<script src="https://unpkg.com/aframe-physics-extras/dist/aframe-physics-extras.min.js"></script>
</head>
<body>
<a-scene physics="debug: true">
<!-- I use body-merger but it works exactly the same with just dynamic-body></-->
<a-entity dynamic-body body-merger position="0 6 -10">
<a-box color="green" position="4 0 0"></a-box>
<a-box color="blue" position="5 0 0"></a-box>
<a-box color="yellow" position="6 0 0"></a-box>
</a-entity>
<a-plane scale="1000 1000 1" color="red" static-body rotation="-90 0 0"></a-plane>
</a-scene>
</body>
</html>
Preview on glitch