how to use transform.GetComponent<ImpactReceiver>() code example Example: unity gameobject.getcomponent rb = GetComponent<Rigidbody>();