void OnTriggerEnter(Collider other) { if (other.CompareTag("Sonic")) { controller.ChangeTimeLimit(2f); Destroy(gameObject); } }
void OnTriggerEnter(Collider other) { if (other.CompareTag("Sonic")) { if (!DashSceneController.isInvincible) { controller.ChangeTimeLimit(-10f); } Destroy(gameObject); } }