Hello !
I've got a little question. I know it's strange to say this (because a body has no shape) but do X and Y positions of a body mean the upper left "corner" of the body ? I think so. Just wanted to be sure.
Printable View
Hello !
I've got a little question. I know it's strange to say this (because a body has no shape) but do X and Y positions of a body mean the upper left "corner" of the body ? I think so. Just wanted to be sure.
The X and Y position of the body is it's center of mass. When you create a shape, you specify it's position as an offset to the position of the body.
Logically, if you create a body containing a single rectangle, and configure the rectangle offset so that the body position is at the top-left of that rectangle, things are gonna look terribly weird as soon as that rectangle starts to rotate.
Thanks, Nifflas. So let's say I create an active object and I center its hotspot. Then let's say I create a body with a position at X(active object) and Y(active object). Then let's say I create a rectangle shape with offset 0 for X and Y. Everything should be right ?
Sounds good yeah.