| Parameter | Description |
|---|---|
| bodies | The bodies to set the callback target on. |
| callbackTarget | The callback target to set on every body, or NULL to remove it. |
int The number of bodies that were ignored (not set because the body was invalid). A single warning is logged when any are ignored.
Set the same Object that event callbacks will be sent to on a batch of bodies. Each body is assigned the callback target as PhysicsBody.callbackTarget would, and setting it to NULL removes it.
This is faster than setting PhysicsBody.callbackTarget on each body.