Hi I am having trouble trying to destroy my enemy clones. How would I go about trying to do it with my enemySpawing and playerHitbox scripts.

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class EnemySpawing : MonoBehaviour
{
public GameObject enemy;
public float respawnTime = 1.0f;
private Vector2 screenBounds;

// Use this for initialization
void Start()
{
    screenBounds = Camera.main.ScreenToWorldPoint(new Vector3(Screen.width, Screen.height, Camera.main.transform.position.z));
    StartCoroutine(enemySpawning());
}

// Spawns Enemys every one second.
private void spawnEnemy()
{
   
    GameObject enemyClone = Instantiate(enemy) as GameObject;
    enemyClone.transform.position = new Vector2(Random.Range(-screenBounds.x * 2, screenBounds.x * 2), Random.Range(-screenBounds.y * 2, screenBounds.y * 2));
}

// Starts spawning when game starts.
IEnumerator enemySpawning()
{
    while (true)
    {
        yield return new WaitForSeconds(respawnTime);
        spawnEnemy();
    }
}

}


using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PlayerHitbox : MonoBehaviour
{
public GameObject enemy;
private PlayerInfo playerInfo;

void Start()
{
    playerInfo = this.GetComponent<PlayerInfo>();
}

// Destorys enemy
private void OnTriggerEnter2D(Collider2D other)
{ 
    playerInfo.plasmaAmount += 1;

    Destroy(enemy);
}

}

If i understand it right, In here i dont see you are actually referencing the object you hit

 private void OnTriggerEnter2D(Collider2D other)
 { 
     playerInfo.plasmaAmount += 1;
     Destroy(enemy); //here you should do something like Destroy(other.gameObject);
 }