private void ShowBodyInfoProperties()
{
this.m_ShowInfo.target = EditorGUILayout.Foldout(this.m_ShowInfo.target, "Info", true);
if (EditorGUILayout.BeginFadeGroup(this.m_ShowInfo.faded))
{
if (base.targets.Length == 1)
{
Rigidbody2D rigidbody2D = base.targets[0] as Rigidbody2D;
EditorGUI.BeginDisabledGroup(true);
EditorGUILayout.Vector2Field("Position", rigidbody2D.position, new GUILayoutOption[0]);
EditorGUILayout.FloatField("Rotation", rigidbody2D.rotation, new GUILayoutOption[0]);
EditorGUILayout.Vector2Field("Velocity", rigidbody2D.velocity, new GUILayoutOption[0]);
EditorGUILayout.FloatField("Angular Velocity", rigidbody2D.angularVelocity, new GUILayoutOption[0]);
EditorGUILayout.FloatField("Inertia", rigidbody2D.inertia, new GUILayoutOption[0]);
EditorGUILayout.Vector2Field("Local Center of Mass", rigidbody2D.centerOfMass, new GUILayoutOption[0]);
EditorGUILayout.Vector2Field("World Center of Mass", rigidbody2D.worldCenterOfMass, new GUILayoutOption[0]);
EditorGUILayout.LabelField("Sleep State", (!rigidbody2D.IsSleeping()) ? "Awake" : "Asleep", new GUILayoutOption[0]);
EditorGUI.EndDisabledGroup();
this.ShowContacts(rigidbody2D);
base.Repaint();
}
else
{
EditorGUILayout.HelpBox("Cannot show Info properties when multiple bodies are selected.", MessageType.Info);
}
}
Rigidbody2DEditor.FixedEndFadeGroup(this.m_ShowInfo.faded);
}