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

PhysicsBody.selectedDrawing

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 bool selectedDrawing;

Description

Controls whether this body is drawn individually when the world is drawn.

The body is only drawn when the world draw options include PhysicsWorld.DrawOptions.SelectedBodies; changing the draw options never changes this state. The state persists until set to false, the body is destroyed, or PhysicsWorld.ClearDrawSelected clears the whole world. The body must also have PhysicsBody.worldDrawing enabled to be drawn.