void OnTriggerEnter(Collider col) { if(onlyOne) if (col.gameObject.tag == "PlayerBody") { onlyOne = false; player = col.gameObject; playerUnit = col.gameObject.GetComponent<PlayerUnit>(); playerUnit.powerUp(playerUnit.powerUpPotion); applyItem(); StartCoroutine("effect"); Destroy(this.gameObject); } }