2D collision getting issue.

I am working on the “2D Vehicle Kit” you can see it asset store easily (its free).

It has 2D car and moves on a Built terrain. I want to add coins on it and add score when the car hits coin.

But i can not get the collision between two of them. Car object is totally using 2D rigid body and other 2D things.

I tried using OnCollision or OnTrigger but didn’t worked.

Some one please help me to get to collision.

add to car boxcollider2D. Move it little befor car. This will pick up coins. Make it trigger (check on in inspector “is trigger”).
add lines in your c# script for pickup. Something like:

public int CoinScore;

void OnTriggerEnter2D (Collider2D other)
{
if (other.gameObject.tag == "Coin")
{
CoinScore +=1;
Destroy (other.gameObject);
}
}

Make coin, add circlecollider2D, make tag of coin Coin. Create prefab for coin. Put coins prefab in your level. Be sure. that you use 2D colliders.