Rigidbody2D pushing in opposite direction

Hi

I’m trying to make an object that is pushed away from the source of impact. Only at the moment i have the rigidbody2D set up to addforce.up. I need it to add the force and push it in the opposite direction of the bullet impact.

using UnityEngine;
using System.Collections;

public class Door : MonoBehaviour {

	//float explosionStrength = 100;
	
	void OnTriggerEnter2D(Collider2D coll) {
		if (coll.gameObject.tag == "Bullet")
		
		this.rigidbody2D.AddForce(Vector2.up * -1000);
		
	}
}

Try this:

void OnTriggerEnter2D(Collider2D coll) {
    if (coll.gameObject.tag == "Bullet") {
        rigidbody2D.AddForce(-coll.rigidbody2D.velocity.normalized * someValue);
    }
}

Where ‘someValue’ is either replaced by a constant or is a variable you define and initialize.