Physics2D.IgnoreLayerCollision(8,9);
Start함수에 이걸 적어주면 해당되는 번호의 레이어끼리는 충돌을 무시한다.
레이어 번호는 Tags & Layers 에서 볼수 있다.
아래는 API
Physics2D.IgnoreLayerCollision
static void IgnoreLayerCollision(int layer1, int layer2, bool ignore = true);
Parameters
| layer1 | ID of the first layer. |
| layer2 | ID of the second layer. |
| ignore | Should collisions between these layers be ignored? |
Description
Choose whether to detect or ignore collisions between a specified pair of layers.
See Also: GetIgnoreLayerCollision.
'유니티 > 스크립트' 카테고리의 다른 글
| 큐브를 사용해서 커다란 보드 만들기. (0) | 2014.02.06 |
|---|---|
| 유니티 2D 메카닉 애니메이션 관련 (0) | 2014.02.05 |
| 레이어 끼리의 충돌 무시하기 (0) | 2014.02.05 |
| 유니티 내에서 List 사용시 (0) | 2014.02.04 |
| 반복되는 배경 만들기(무한 스크롤링) - 근경 (0) | 2014.02.04 |
| 반복되는 배경 만들기(무한 스크롤링) - 원경 (6) | 2014.02.04 |
Trackback 0 And
Comment 0


