Change Body Size

When using physics, the actual interaction between objects – collision, overlapping etc. – is done between their physics bodies. And the dimensions of these bodies can be changed:


The width and height of the body are the dimensions of the invisible body rectangle, located around the anchor of the sprite (set in the Settings panel). Instead of anchoring, you can also offset the point out of which the body is ‘drawn’.

You should only change these parameters from the defaults if the image file has some blank parts, so the game interacts only with the area you want, not the blank parts.

Full sample available here.

Leave a Reply

Your email address will not be published. Required fields are marked *