Наследование: VJAbstractManager
Пример #1
0
 // Use this for initialization
 public void Awake()
 {
     if( lowerBand >= VJManager.numberOfBands ) {
         Debug.LogWarning("[FATAL]lowerBand too large.");
         lowerBand = VJManager.numberOfBands-1;
     }
     if( upperBand >= VJManager.numberOfBands ) {
         Debug.LogWarning("[FATAL]lowerBand too large.");
         upperBand = VJManager.numberOfBands-1;
     }
     if( upperBand < lowerBand ) {
         Debug.LogWarning("upperBand can not be lower than lowerBand.");
         upperBand = lowerBand;
     }
     m_manager = GetComponent<VJManager>();
 }
Пример #2
0
    public override void OnInspectorGUI()
    {
        GUI.changed = false;

        base.OnInspectorGUI();

        VJManager manager = target as VJManager;
        bool      b       = EditorGUILayout.Toggle("Use Microphone", manager.isMicSource);

        if (b != manager.isMicSource)
        {
            manager.ToogleMicSource(b);
        }

        if (GUI.changed)
        {
            EditorUtility.SetDirty(target);
        }
    }
Пример #3
0
 // Use this for initialization
 public void Awake()
 {
     if (lowerBand >= VJManager.numberOfBands)
     {
         Debug.LogWarning("[FATAL]lowerBand too large.");
         lowerBand = VJManager.numberOfBands - 1;
     }
     if (upperBand >= VJManager.numberOfBands)
     {
         Debug.LogWarning("[FATAL]lowerBand too large.");
         upperBand = VJManager.numberOfBands - 1;
     }
     if (upperBand < lowerBand)
     {
         Debug.LogWarning("upperBand can not be lower than lowerBand.");
         upperBand = lowerBand;
     }
     m_manager = GetComponent <VJManager>();
 }
Пример #4
0
    public override void OnInspectorGUI()
    {
        base.OnInspectorGUI();

        serializedObject.Update();

        bool b = EditorGUILayout.Toggle("Use Microphone", isMicSourceProperty.boolValue);

        if (serializedObject.isEditingMultipleObjects)
        {
            foreach (UnityEngine.Object o in targets)
            {
                VJManager m = o as VJManager;

                if (GUI.changed)
                {
                    if (m.isMicSource != b)
                    {
                        m.ToogleMicSource(b);
                    }
                }
            }
        }
        else
        {
            VJManager m = target as VJManager;
            if (GUI.changed)
            {
                if (m.isMicSource != b)
                {
                    m.ToogleMicSource(b);
                }
            }
        }

        serializedObject.ApplyModifiedProperties();
    }
Пример #5
0
 // Use this for initialization
 public void Awake()
 {
     m_manager = GetComponent <VJManager>();
 }
Пример #6
0
 // Use this for initialization
 public void Awake()
 {
     m_manager = GetComponent<VJManager>();
 }