Exemple #1
0
        private void OnEnable()
        {
            button = serializedObject.targetObject as KGUI_ButtonObject;

            if (buttonType == null)
            {
                buttonType = new KGUIButtonTypeEditor();
            }
            if (buttonEvent == null)
            {
                buttonEvent = new KGUIButtonEventEditor();
            }

            if (buttonAudio == null)
            {
                buttonAudio = new KGUIButtonAudioEditor();
            }

            buttonType.OnInstantiation(serializedObject);
            buttonEvent.OnInstantiation(serializedObject);
            buttonAudio.OnInstantiation(serializedObject);

            onGroupReset = serializedObject.FindProperty("onGroupReset");

            BindObject = serializedObject.FindProperty("bindObject");
            Panel      = serializedObject.FindProperty("panel");
        }
        private void OnEnable()
        {
            button = serializedObject.targetObject as KGUI_ButtonObject;

            if (buttonType == null)
            {
                buttonType = new KGUIButtonTypeEditor();
            }
            if (buttonEvent == null)
            {
                buttonEvent = new KGUIButtonEventEditor();
            }

            onGroupReset = serializedObject.FindProperty("onGroupReset");

            AudioClip = serializedObject.FindProperty("audioClip");

            BindObject = serializedObject.FindProperty("bindObject");
            Panel      = serializedObject.FindProperty("panel");
        }