Re: body:getposition with multiple shapes
Posted: Sun Oct 13, 2019 10:44 pm
That's a bug in PhysRenderer.lua, not in love.physics. I tried replacing it with Azhukar's debugWorldDraw and the circle changed position the expected way.zell2002 wrote: ↑Sun Oct 13, 2019 10:18 pm So this is a barebones demo - a world with a static box, then if you press spacebar it will create a "player" this player will be a rectangle with 2 extra shapes added to the same body. One shape is another rectangle and its offset is taken into account, the other is a circle and it doesnt matter what offsets you give it, they are not used at all. Even changing the ordering of when the shapes are made do not change where the circle is built. It is always built at 0,0 of the body.
In fact, the part of PhysRenderer that draws the circle always draws it at relative coordinates 0, 0. It doesn't use CircleShape:getPoint at all.