Search Unity

2D platformer. Why the two enemies can pass through each other without collision?

Discussion in '2D' started by LouisYin, Aug 25, 2016.

  1. LouisYin

    LouisYin

    Joined:
    Aug 25, 2016
    Posts:
    4
  2. LiterallyJeff

    LiterallyJeff

    Joined:
    Jan 21, 2015
    Posts:
    2,807
    Make sure they both have colliders with IsTrigger unchecked. Make sure at least one has a rigidbody. Make sure they are both on layers that are defined to collide in the Physics2D collision matrix found in Edit -> Project Settings -> Physics2D.