Tests if a rigid body is sleeping. See unity docs: Rigidbody Sleeping.
The game object to test.
Event to send if sleeping.
Event to send if not sleeping.
Store the result in a bool variable.
Test every frame. Useful if you want to wait until sleeping is true/false.