using UnityEngine; public class UpgradePickupEffects : MonoBehaviour { [SerializeField] private UpgradePickup thisPickup; public void OnTriggerEnter2D(Collider2D other) { if (other.CompareTag(tag)) { thisPickup.PickupEffects(); Destroy(gameObject); } } }