Detect different death sources?

Hi,
I have a simple Health system for my little enemy.(When health <0 die) How do I detect different death types/last source that killed the enemy? Like if the enemy got killed by a bullet/explosion/fall or detecting who fired the shot that killed it? Is there some ways to do this by broadcasting messages or are there other ways of achieving this? Please help in JS, THANKS!

var lives = 100;

 function OnTriggerEnter ( hit : Collider)
 {
	 if (hit.gameObject.tag == "weapon1")
	 {
	     lives -= //add lives number;  // (can be more/less then the other bullets)
		 
		 Destroy(hit.gameObject);
		 //do someting
		 
		 if (lives <= 0)
	     {
	         //dead
			 print ("killed by weapon1");
	     }
	 }
	 if (hit.gameObject.tag == "weapon2")
	 {
	     lives -= //add lives number;  // (can be more/less then the other bullets)
		 Destroy(hit.gameObject);
		 //do someting
		 
		 if (lives <= 0)
	     {
	         //dead
			 print ("killed by weapon2");
	     }
	 }
	 if (hit.gameObject.tag == "weapon3")
	 {
	     lives -= //add lives number;  // (can be more/less then the other bullets)
		 
		 Destroy(hit.gameObject);
		 //do someting
		 
		 if (lives <= 0)
	     {
	         //dead
			 print ("killed by weapon3");
	     }
	 }
 }

You add this code to the enemy and the enemy will act differantly according to the weapon/bullet that hit him. if his lives <= to 0, it will print who/what killed him.

i know an efficent way that might not be as easy as you like.
create a component called deathSource for all objects that can cause death and then in OnTriigerEnter /OnCollisionEnter that you check for death events take the reference of the object that is reducing your health and get it’s deathSource component using GetComponent and for each object put it’s information like name and deathtype in the component to retreive.