private void OnTriggerEnter2D(Collider2D collision) { GameObject objectThing = collision.gameObject; if (objectThing.CompareTag("PlayerGRAY") || objectThing.CompareTag("PlayerPINK")) { PlayerStateManager.AddItems(type, value); Destroy(gameObject); } }