Game Development Reference
In-Depth Information
2.
To get chains and ropes to collide with borders (and not just triggers), add
obstacle to each border's mask (player, obstacle) and add border to each
chain and rope node's mask (player, obstacle, border). (See Table 9-3 .)
Table 9-3 . Settings to allow chains and ropes to collide
with borders
3.
The final scenario assumes you want ropes to collide only with ropes and
chains to collide only with chains. This requires all chain and rope nodes to
have unique categories, correspondingly named chain and rope , and include
them in their collision mask (player, chain/player, rope). You would have to
edit the masks of player (trigger, border, chain, rope) and, optionally, all bor-
der nodes (player, chain, rope) to include the chain and rope categories. The
obstacle category can be removed from all masks. (See Table 9-4 .)
Table 9-4 . Settings to allow chains to collide with chains and ropes
collide with ropes, but prevent chains from colliding with ropes. Play-
er and borders collide with both chains and ropes
Creating a Springboard
Creating a springboard obviously involves using the spring joint. But you'll also need a
distance joint to keep the spring locked until activated—just like an archer keeps the
string pulled backward on her bow until she releases her grip on the string to fire the ar-
row.
Search WWH ::




Custom Search