Esempio n. 1
0
        internal Vector3 Handle(int number, BGCurveSettings.HandlesTypeEnum type, Vector3 position, Quaternion rotation, BGCurveSettings.SettingsForHandles handlesSettings)
        {
            switch (type)
            {
            case BGCurveSettings.HandlesTypeEnum.FreeMove:
                position = Handles.FreeMoveHandle(position, rotation, BGEditorUtility.GetHandleSize(position, .2f), Vector3.zero, Handles.CircleCap);
                break;

            case BGCurveSettings.HandlesTypeEnum.Standard:
                position = Handles.PositionHandle(position, rotation);
                break;

            case BGCurveSettings.HandlesTypeEnum.Configurable:
                position = BGEditorUtility.ControlHandleCustom(number, position, rotation, handlesSettings);
                break;
            }
            return(position);
        }