Need help with AI script

Hello…I need some help with my script, my player can shoot fireballs and can respawn when it touches the enemy, but if i duplicate my enemy and destroy one of them, both of them are destroyed. If anyone knows whats wrong with my script so only one enemy gets destroyed, please help. Heres my script:

#pragma strict 
var health = 10;
var TakeDamage : boolean;

function OnTriggerEnter(other : Collider){
	if(other.tag == "Player"){
	  TakeDamage = true;
	}
}

function OnTriggerExit(other : Collider){
	if(other.tag == "Player"){
	  TakeDamage = false;
	}
}

function Update(){
	if(TakeDamage){
	  if(Input.GetButtonDown("Fire1")){
	      health --;
	    }
	}
	if(health<= 0){
	print("Enemy Down");
	health = 0;
	Destroy(gameObject);
	}
}

Try this maybe it works,

#pragma strict 
var health = 10;
var TakeDamage : boolean;
var myCollider : Collider;

function OnTriggerEnter(other : Collider){
    if(other.tag == "Player"){
      TakeDamage = true;
    }
    myCollider = other;
}

function OnTriggerExit(other : Collider){
    if(other.tag == "Player"){
      TakeDamage = false;
    }
}


function Update(){
    if(TakeDamage){
      if(Input.GetButtonDown("Fire1")){
          health --;
        }
    }
    if(health<= 0){
    print("Enemy Down");
    health = 0;
	    if(myCollider != null)
	    {
	    Destroy(myCollider.gameObject);
	    }
    }
    
}

hi What did you put the script on enemy or caracter
plzz answer as i am having the same trouble