Beispiel #1
0
        public static void Init(UIAnimator animator)
        {
            // Get existing open window or if none, make a new one:
            W_UIAnimator window = (W_UIAnimator)EditorWindow.GetWindow(typeof(W_UIAnimator), false, "Animator Editor");

            window.minSize = new Vector2(420, 300);
        }
Beispiel #2
0
        public override void OnInspectorGUI()
        {
            if (GUILayout.Button("Open Animation Editor"))
            {
                W_UIAnimator.Init((UIAnimator)target);
            }

            /*
             * if(m_animator == null)
             *  m_animator = (UIAnimator) target;
             * for (int n = 0 ; n < m_animator.AnimationList.Count ; n++)
             * {
             *  DrawUIAnimation(m_animator.AnimationList[n]);
             *
             *  if (GUILayout.Button("Play"))
             *  {
             *      m_animator.AnimationList[n].Play();
             *      Debug.Log("click");
             *  }
             * }
             */
        }