private void OnTriggerEnter(Collider other) { if (other.gameObject.tag == "Food") { GameObject particleSystemInstance = Instantiate(particleSystemPrefab, other.transform.position, Quaternion.identity); particleSystemInstance.AddComponent <AutoDestroy>(); Destroy(other.gameObject); dragonController.StartEating(); scoreBoard.SetScore(10); // TODO: Set different scores for different food } }