Handle scaled bodies properly

This commit is contained in:
Richard Davey 2020-01-10 17:03:50 +00:00
parent c9a98088b6
commit d884fd0468

View file

@ -155,7 +155,7 @@ var SetBody = {
var cx = body.centerOffset.x;
var cy = body.centerOffset.y;
this.setOrigin(rx + (cx / this.width), ry + (cy / this.height));
this.setOrigin(rx + (cx / this.displayWidth), ry + (cy / this.displayHeight));
}
return this;