Is this unity? If so then instead of collisonInfo.collider.tag=="1", use collisionInfo.collider.gameObject.CompareTag("1")