Collision between a flare and a object doesn't occur...

Hey There!

So I’ve this problem where I’m trying to make a “space torpedo” hit the target, however when both colliders interact, the script that destroys the torpedo doesn’t work, and the torpedo stays there indefinitely…

The Ship has a group of 6 colliders, and the torpedo is an empty game object with a sphere Collider and a lens flare inside it. In order to the lens flare glow through the collider, I placed the primary game object in a TransparentFX layer.

And then I’ve this script that checks if it doesn’t collide with the object that fired it, and if it hits a target, destroys itself:

function OnCollisionEnter (hit : Collision) {
	
	if (hit.transform != launched.transform)
	{
		
		Destroy(gameObject);
Instantiate(explosion.transform.gameObject, transform.position, transform.rotation);

	
	}

}

So, anyone can tell me what’s been done wrong here?

Thanks in advance.

JPB18

EDIT: Here’s the script responsible for the torpedo movement (also changed the collision script):

function FixedUpdate () {

	if ( isCalc != true)
	{
	//calc the flight time
		var time = travel_time(target.position, launched.position, speed);
		isCalc = true;
	}
	//fly!!!!
	StartCoroutine(flight(transform, launched.position, target.position, time));
			
		
		

}

//calculates the distance between the origin and the target

function travel_time(target : Vector3, start : Vector3, speed : float) {

	var distance = Vector3.Distance(start, target);
	return distance/speed;	

}

//flight Coroutine
function flight (ThisTransform : Transform, startPos : Vector3, endPos : Vector3, time : float)
{
	var i : float = 0;
	var rate : float = 1/time * Time.deltaTime;
	
	while (i < 1)
	{
		i += rate;
		ThisTransform.position = Vector3.Lerp(startPos, endPos,i);
		yield;
	}


}

I would imagine it’s a need for Rigidbodies - see this article