Defold-box2d Box2D extension

About frame lag.
This topic?
Dealing with the one frame lag when visualising dynamic bodies - #6 by Mathias_Westerdahl
if i understand correctly problem happened because script update is called before physics update?

In this extenstion you update physics manualy in script.

function update(self, dt)
    self.world:Step(1 / 60, 8, 3)
    self.world:DebugDraw()
end

Also you always get actual possition by body:GetPosition()

2 Likes