0
0
Fork 0
mirror of https://github.com/liabru/matter-js.git synced 2024-12-26 13:49:01 -05:00

added support for sprite scale in RenderPixi, closes #54

This commit is contained in:
liabru 2014-12-28 18:23:48 +00:00
parent 4746eb9348
commit 8dea1666f7

View file

@ -314,6 +314,8 @@ var RenderPixi = {};
sprite.position.x = body.position.x;
sprite.position.y = body.position.y;
sprite.rotation = body.angle;
sprite.scale.x = bodyRender.sprite.xScale || 1;
sprite.scale.y = bodyRender.sprite.yScale || 1;
} else {
var primitiveId = 'b-' + body.id,
primitive = render.primitives[primitiveId],
@ -426,4 +428,4 @@ var RenderPixi = {};
return texture;
};
})();
})();