Пример #1
0
        private void HandConfigurationInspector(ref HandTarget.TargetedHandBone hand, bool isLeft)
        {
            hand.bone.transform = (Transform)EditorGUILayout.ObjectField("Hand Bone", hand.bone.transform, typeof(Transform), true);
            if (hand.bone.transform != null)
            {
                EditorGUI.indentLevel++;

                handJointLimitations.boolValue = EditorGUILayout.Toggle("Joint Limitations", hand.bone.jointLimitations);
                if (hand.bone.jointLimitations)
                {
                    handLimitationAngle.floatValue = EditorGUILayout.Slider("Max Angle", hand.bone.maxAngle, 0, 180);
                }

                EditorGUI.indentLevel--;
            }
        }
Пример #2
0
 private void InitHandConfiguration(HandTarget.TargetedHandBone hand)
 {
     handJointLimitations = serializedObject.FindProperty("hand.bone.jointLimitations");
     handLimitationAngle  = serializedObject.FindProperty("hand.bone.maxAngle");
 }