Version: Unity 7.0 Alpha (7000.0)
LanguageEnglish
  • C#

PhysicsWorld.callbackTargetCount

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

public int callbackTargetCount;

Description

Get the number of distinct callback targets held by the bodies, chains, shapes and joints in the world. Objects that share the same callback target object count it once, however many of them there are.

See PhysicsBody.callbackTarget, PhysicsChain.callbackTarget, PhysicsShape.callbackTarget and PhysicsJoint.callbackTarget. A callback target set on a shape or joint that is destroyed along with its body, or on a chain segment destroyed along with its chain, can still be counted until the world reuses that object's handle or the world is destroyed.