I cant get OnCollisionEnter to work with objects with 2D colliders and Rigidbody2D. OnTriggerEnter works if collider set to trigger.
This object has 2D Colliders and a RigidBody2d. The colliding object as well.
void OnCollisionEnter (Collision collision)
{
print ("Zombieboy Collision");
var x = 0;
switch (collision.gameObject.name) {
case ("Martha(Clone)"):
arrivedAtTarget = true;
print ("Gotcha");
break;
default:
break;
}
}