private void OnCollisionEnter2D(Collision2D col) { if (col.gameObject.tag == "Player") { scrtim.decreaseHealth(20); } }
private void OnTriggerEnter2D(Collider2D col) { if (col.gameObject.tag == "Player") { scrtim.decreaseHealth(20); } }