How do you identify enemies in a script?

i have three turrets and when i destroy them i wanna advance to the next level, but in my script how do i let the computer know what the turrets are?

My Script:

public var arrIsTurretAlive: boolean[];

public function TurretDestroyed(nTurretID: int) { arrIsTurretAlive[nTurretID] = false;

    var bWasLiveTurretFound: boolean = false;
    for (var nCurrTurret: int = 0 ; nCurrTurret < arrIsTurretAlive.Length ; nCurrTurret++)
{   
    if (arrIsTurretAlive[nCurrTurret])
    {
        bWasLiveTurretFound = true;
        break;
    }
}

if(!bWasLiveTurretFound)
    Application.LoadLevel(Application.loadedLevel + 1);

}

p.s. i have the script attached to an invisible "dummy" object.

Take advantage of "tags".

Use "Tags" inside the Editor to assign a specific "Tag" (e.g. "Create new Tag") to a specific object or Prefab to assign a "role" to an object. You may call on the tag later on or run several checks like

if(gameobject.tag == "enemy")
    Destroy(gamobject);