Game Development Reference
In-Depth Information
In the Details Inspector on the Item Physics tab, select the “Enable physics”
check box. Then change the body's type to Static and ensure “Physics shape” is set to
Polygon. See Figure 4-6 for reference.
Figure 4-6 . A static border image's physics settings
Editing Physics Shapes
With the Physics shape set to Polygon, you can manually modify the body's shape. Notice
how the selection rectangle's corner handles have changed color? Previously, they were a
grayish blue, but now they are pinkish, uhm, pink. Who picks these colors, anyway?
The pink handles tell you that you can drag and drop individual corner points to change
the polygon shape. Try clicking and dragging some of the selection corners to create a
shape like the one shown in Figure 4-7 .
Figure 4-7 . Border image's physics shape rectangle slightly modified
Tip When you switch to another Details Inspector tab other than the Item
Physics tab, the regular selection rectangle will appear and you can no longer
edit the physics shape. In order to view and edit a node's physics shape, you
have to be on the Item Physics tab.
Search WWH ::




Custom Search