Version: Unity 6.7 Alpha (6000.7)
LanguageEnglish
  • C#

PhysicsBody.drawTarget

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 DrawTarget drawTarget;

Description

Controls which Unity editor views this body is drawn into.

This filters on top of the world's own PhysicsWorld.drawTarget: the world decides whether it draws into a view at all, and this decides whether this body is included when it does. The state is not part of the body definition and is never recorded, because it describes how the body is being looked at rather than what it is. A player build has no Scene view, so a body set to PhysicsWorld.DrawTarget.SceneView is never drawn in a build.